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

Side by Side Diff: sky/engine/core/rendering/RenderLayerClipper.cpp

Issue 735033003: Remove a bunch of dead code from RenderLayer (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: cr comments Created 6 years 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) 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 304 matching lines...) Expand 10 before | Expand all | Expand 10 after
315 { 315 {
316 if (context.usesCache()) 316 if (context.usesCache())
317 clipRects = *getClipRects(context); 317 clipRects = *getClipRects(context);
318 else 318 else
319 calculateClipRects(context, clipRects); 319 calculateClipRects(context, clipRects);
320 } 320 }
321 321
322 RenderLayer* RenderLayerClipper::clippingRootForPainting() const 322 RenderLayer* RenderLayerClipper::clippingRootForPainting() const
323 { 323 {
324 const RenderLayer* current = m_renderer.layer(); 324 const RenderLayer* current = m_renderer.layer();
325 if (current->isPaintInvalidationContainer())
326 return const_cast<RenderLayer*>(current);
327
328 while (current) { 325 while (current) {
329 if (current->isRootLayer()) 326 if (current->isRootLayer())
330 return const_cast<RenderLayer*>(current); 327 return const_cast<RenderLayer*>(current);
331 328
332 current = current->compositingContainer(); 329 current = current->compositingContainer();
333 ASSERT(current); 330 ASSERT(current);
334 if (current->transform() || current->isPaintInvalidationContainer()) 331 if (current->transform())
335 return const_cast<RenderLayer*>(current); 332 return const_cast<RenderLayer*>(current);
336 } 333 }
337 334
338 ASSERT_NOT_REACHED(); 335 ASSERT_NOT_REACHED();
339 return 0; 336 return 0;
340 } 337 }
341 338
342 } // namespace blink 339 } // namespace blink
OLDNEW
« no previous file with comments | « sky/engine/core/rendering/RenderLayer.cpp ('k') | sky/engine/core/rendering/RenderLayerModelObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698