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

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

Issue 295513003: add 'slow' prefix to RenderObject's firstChild() / lastChild() methods (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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
« no previous file with comments | « Source/core/rendering/RenderLayer.cpp ('k') | Source/core/rendering/RenderListItem.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 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
161 // Sort the two lists. 161 // Sort the two lists.
162 if (m_posZOrderList) 162 if (m_posZOrderList)
163 std::stable_sort(m_posZOrderList->begin(), m_posZOrderList->end(), compa reZIndex); 163 std::stable_sort(m_posZOrderList->begin(), m_posZOrderList->end(), compa reZIndex);
164 164
165 if (m_negZOrderList) 165 if (m_negZOrderList)
166 std::stable_sort(m_negZOrderList->begin(), m_negZOrderList->end(), compa reZIndex); 166 std::stable_sort(m_negZOrderList->begin(), m_negZOrderList->end(), compa reZIndex);
167 167
168 // Append layers for top layer elements after normal layer collection, to en sure they are on top regardless of z-indexes. 168 // Append layers for top layer elements after normal layer collection, to en sure they are on top regardless of z-indexes.
169 // The renderers of top layer elements are children of the view, sorted in t op layer stacking order. 169 // The renderers of top layer elements are children of the view, sorted in t op layer stacking order.
170 if (layer()->isRootLayer()) { 170 if (layer()->isRootLayer()) {
171 RenderObject* view = renderer()->view(); 171 RenderView* view = renderer()->view();
172 for (RenderObject* child = view->firstChild(); child; child = child->nex tSibling()) { 172 for (RenderObject* child = view->firstChild(); child; child = child->nex tSibling()) {
173 Element* childElement = (child->node() && child->node()->isElementNo de()) ? toElement(child->node()) : 0; 173 Element* childElement = (child->node() && child->node()->isElementNo de()) ? toElement(child->node()) : 0;
174 if (childElement && childElement->isInTopLayer()) { 174 if (childElement && childElement->isInTopLayer()) {
175 RenderLayer* layer = toRenderLayerModelObject(child)->layer(); 175 RenderLayer* layer = toRenderLayerModelObject(child)->layer();
176 // Create the buffer if it doesn't exist yet. 176 // Create the buffer if it doesn't exist yet.
177 if (!m_posZOrderList) 177 if (!m_posZOrderList)
178 m_posZOrderList = adoptPtr(new Vector<RenderLayerStackingNod e*>); 178 m_posZOrderList = adoptPtr(new Vector<RenderLayerStackingNod e*>);
179 m_posZOrderList->append(layer->stackingNode()); 179 m_posZOrderList->append(layer->stackingNode());
180 } 180 }
181 } 181 }
(...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after
372 return ancestor->stackingNode(); 372 return ancestor->stackingNode();
373 return 0; 373 return 0;
374 } 374 }
375 375
376 RenderLayerModelObject* RenderLayerStackingNode::renderer() const 376 RenderLayerModelObject* RenderLayerStackingNode::renderer() const
377 { 377 {
378 return m_layer->renderer(); 378 return m_layer->renderer();
379 } 379 }
380 380
381 } // namespace WebCore 381 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderLayer.cpp ('k') | Source/core/rendering/RenderListItem.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698