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

Side by Side Diff: third_party/WebKit/Source/core/layout/compositing/CompositedLayerMapping.cpp

Issue 2194913002: Ensure that we consistently check contains: paint for fixed position containment. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2785
Patch Set: Created 4 years, 4 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) 2009, 2010, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2009, 2010, 2011 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 1085 matching lines...) Expand 10 before | Expand all | Expand 10 after
1096 // Register fixed position layers and their containers with the scrolling co ordinator. 1096 // Register fixed position layers and their containers with the scrolling co ordinator.
1097 ScrollingCoordinator* scrollingCoordinator = scrollingCoordinatorFromLayer(m _owningLayer); 1097 ScrollingCoordinator* scrollingCoordinator = scrollingCoordinatorFromLayer(m _owningLayer);
1098 if (!scrollingCoordinator) 1098 if (!scrollingCoordinator)
1099 return; 1099 return;
1100 1100
1101 scrollingCoordinator->updateLayerPositionConstraint(&m_owningLayer); 1101 scrollingCoordinator->updateLayerPositionConstraint(&m_owningLayer);
1102 1102
1103 // Page scale is applied as a transform on the root layout view layer. Becau se the scroll 1103 // Page scale is applied as a transform on the root layout view layer. Becau se the scroll
1104 // layer is further up in the hierarchy, we need to avoid marking the root l ayout view 1104 // layer is further up in the hierarchy, we need to avoid marking the root l ayout view
1105 // layer as a container. 1105 // layer as a container.
1106 bool isContainer = m_owningLayer.hasTransformRelatedProperty() && !m_owningL ayer.isRootLayer(); 1106 bool isContainer = m_owningLayer.layoutObject()->style()->canContainFixedPos itionObjects() && !m_owningLayer.isRootLayer();
1107 // FIXME: we should make certain that childForSuperLayers will never be the m_squashingContainmentLayer here 1107 // FIXME: we should make certain that childForSuperLayers will never be the m_squashingContainmentLayer here
1108 scrollingCoordinator->setLayerIsContainerForFixedPositionLayers(childForSupe rlayers(), isContainer); 1108 scrollingCoordinator->setLayerIsContainerForFixedPositionLayers(childForSupe rlayers(), isContainer);
1109 } 1109 }
1110 1110
1111 void CompositedLayerMapping::updateInternalHierarchy() 1111 void CompositedLayerMapping::updateInternalHierarchy()
1112 { 1112 {
1113 // m_foregroundLayer has to be inserted in the correct order with child laye rs, 1113 // m_foregroundLayer has to be inserted in the correct order with child laye rs,
1114 // so it's not inserted here. 1114 // so it's not inserted here.
1115 if (m_ancestorClippingLayer) 1115 if (m_ancestorClippingLayer)
1116 m_ancestorClippingLayer->removeAllChildren(); 1116 m_ancestorClippingLayer->removeAllChildren();
(...skipping 1552 matching lines...) Expand 10 before | Expand all | Expand 10 after
2669 } else if (graphicsLayer == m_scrollingContentsLayer.get()) { 2669 } else if (graphicsLayer == m_scrollingContentsLayer.get()) {
2670 name = "Scrolling Contents Layer"; 2670 name = "Scrolling Contents Layer";
2671 } else { 2671 } else {
2672 ASSERT_NOT_REACHED(); 2672 ASSERT_NOT_REACHED();
2673 } 2673 }
2674 2674
2675 return name; 2675 return name;
2676 } 2676 }
2677 2677
2678 } // namespace blink 2678 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/layout/MapCoordinatesTest.cpp ('k') | third_party/WebKit/Source/core/paint/PaintLayer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698