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

Side by Side Diff: Source/WebCore/rendering/RenderLayerBacking.cpp

Issue 9342003: Merge 106459 - Fix the semantics of passing contentsVisible flag to GraphicsLayers (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1025/
Patch Set: Created 8 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 | « LayoutTests/platform/chromium/test_expectations.txt ('k') | no next file » | 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) 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 385 matching lines...) Expand 10 before | Expand all | Expand 10 after
396 396
397 // Set opacity, if it is not animating. 397 // Set opacity, if it is not animating.
398 if (!renderer()->animation()->isRunningAcceleratedAnimationOnRenderer(render er(), CSSPropertyOpacity)) 398 if (!renderer()->animation()->isRunningAcceleratedAnimationOnRenderer(render er(), CSSPropertyOpacity))
399 updateLayerOpacity(renderer()->style()); 399 updateLayerOpacity(renderer()->style());
400 400
401 #if ENABLE(CSS_FILTERS) 401 #if ENABLE(CSS_FILTERS)
402 updateLayerFilters(renderer()->style()); 402 updateLayerFilters(renderer()->style());
403 #endif 403 #endif
404 404
405 m_owningLayer->updateVisibilityStatus(); 405 m_owningLayer->updateVisibilityStatus();
406 m_graphicsLayer->setContentsVisible(m_owningLayer->hasVisibleContent()); 406
407 407 // m_graphicsLayer is the corresponding GraphicsLayer for this RenderLayer a nd its non-compositing
408 // descendants. So, the visibility flag for m_graphicsLayer should be true i f there are any
409 // non-compositing visible layers.
410 m_graphicsLayer->setContentsVisible(m_owningLayer->hasVisibleContent() || ha sVisibleNonCompositingDescendantLayers());
411
408 RenderStyle* style = renderer()->style(); 412 RenderStyle* style = renderer()->style();
409 m_graphicsLayer->setPreserves3D(style->transformStyle3D() == TransformStyle3 DPreserve3D && !renderer()->hasReflection()); 413 m_graphicsLayer->setPreserves3D(style->transformStyle3D() == TransformStyle3 DPreserve3D && !renderer()->hasReflection());
410 m_graphicsLayer->setBackfaceVisibility(style->backfaceVisibility() == Backfa ceVisibilityVisible); 414 m_graphicsLayer->setBackfaceVisibility(style->backfaceVisibility() == Backfa ceVisibilityVisible);
411 415
412 RenderLayer* compAncestor = m_owningLayer->ancestorCompositingLayer(); 416 RenderLayer* compAncestor = m_owningLayer->ancestorCompositingLayer();
413 417
414 // We compute everything relative to the enclosing compositing layer. 418 // We compute everything relative to the enclosing compositing layer.
415 LayoutRect ancestorCompositingBounds; 419 LayoutRect ancestorCompositingBounds;
416 if (compAncestor) { 420 if (compAncestor) {
417 ASSERT(compAncestor->backing()); 421 ASSERT(compAncestor->backing());
(...skipping 976 matching lines...) Expand 10 before | Expand all | Expand 10 after
1394 1398
1395 if (m_graphicsLayer->drawsContent()) 1399 if (m_graphicsLayer->drawsContent())
1396 return m_graphicsLayer->usingTiledLayer() ? TiledCompositingLayer : Norm alCompositingLayer; 1400 return m_graphicsLayer->usingTiledLayer() ? TiledCompositingLayer : Norm alCompositingLayer;
1397 1401
1398 return ContainerCompositingLayer; 1402 return ContainerCompositingLayer;
1399 } 1403 }
1400 1404
1401 } // namespace WebCore 1405 } // namespace WebCore
1402 1406
1403 #endif // USE(ACCELERATED_COMPOSITING) 1407 #endif // USE(ACCELERATED_COMPOSITING)
OLDNEW
« no previous file with comments | « LayoutTests/platform/chromium/test_expectations.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698