OLD | NEW |
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 495 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
506 if (RuntimeEnabledFeatures::cssCompositingEnabled()) | 506 if (RuntimeEnabledFeatures::cssCompositingEnabled()) |
507 updateLayerBlendMode(renderer()->style()); | 507 updateLayerBlendMode(renderer()->style()); |
508 | 508 |
509 bool isSimpleContainer = isSimpleContainerCompositingLayer(); | 509 bool isSimpleContainer = isSimpleContainerCompositingLayer(); |
510 | 510 |
511 m_owningLayer->updateDescendantDependentFlags(); | 511 m_owningLayer->updateDescendantDependentFlags(); |
512 | 512 |
513 // m_graphicsLayer is the corresponding GraphicsLayer for this RenderLayer a
nd its non-compositing | 513 // m_graphicsLayer is the corresponding GraphicsLayer for this RenderLayer a
nd its non-compositing |
514 // descendants. So, the visibility flag for m_graphicsLayer should be true i
f there are any | 514 // descendants. So, the visibility flag for m_graphicsLayer should be true i
f there are any |
515 // non-compositing visible layers. | 515 // non-compositing visible layers. |
516 m_graphicsLayer->setContentsVisible(m_owningLayer->hasVisibleContent() || ha
sVisibleNonCompositingDescendantLayers()); | 516 bool contentsVisible = m_owningLayer->hasVisibleContent() || hasVisibleNonCo
mpositingDescendantLayers(); |
| 517 if (RuntimeEnabledFeatures::overlayFullscreenVideoEnabled() && renderer()->i
sVideo()) { |
| 518 HTMLMediaElement* mediaElement = toHTMLMediaElement(renderer()->node()); |
| 519 if (mediaElement->isFullscreen()) |
| 520 contentsVisible = false; |
| 521 } |
| 522 m_graphicsLayer->setContentsVisible(contentsVisible); |
517 | 523 |
518 RenderStyle* style = renderer()->style(); | 524 RenderStyle* style = renderer()->style(); |
519 // FIXME: reflections should force transform-style to be flat in the style:
https://bugs.webkit.org/show_bug.cgi?id=106959 | 525 // FIXME: reflections should force transform-style to be flat in the style:
https://bugs.webkit.org/show_bug.cgi?id=106959 |
520 bool preserves3D = style->transformStyle3D() == TransformStyle3DPreserve3D &
& !renderer()->hasReflection(); | 526 bool preserves3D = style->transformStyle3D() == TransformStyle3DPreserve3D &
& !renderer()->hasReflection(); |
521 m_graphicsLayer->setPreserves3D(preserves3D); | 527 m_graphicsLayer->setPreserves3D(preserves3D); |
522 m_graphicsLayer->setBackfaceVisibility(style->backfaceVisibility() == Backfa
ceVisibilityVisible); | 528 m_graphicsLayer->setBackfaceVisibility(style->backfaceVisibility() == Backfa
ceVisibilityVisible); |
523 | 529 |
524 RenderLayer* compAncestor = m_owningLayer->ancestorCompositingLayer(); | 530 RenderLayer* compAncestor = m_owningLayer->ancestorCompositingLayer(); |
525 | 531 |
526 // We compute everything relative to the enclosing compositing layer. | 532 // We compute everything relative to the enclosing compositing layer. |
(...skipping 1432 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1959 } else if (graphicsLayer == m_scrollingContentsLayer.get()) { | 1965 } else if (graphicsLayer == m_scrollingContentsLayer.get()) { |
1960 name = "Scrolling Contents Layer"; | 1966 name = "Scrolling Contents Layer"; |
1961 } else { | 1967 } else { |
1962 ASSERT_NOT_REACHED(); | 1968 ASSERT_NOT_REACHED(); |
1963 } | 1969 } |
1964 | 1970 |
1965 return name; | 1971 return name; |
1966 } | 1972 } |
1967 | 1973 |
1968 } // namespace WebCore | 1974 } // namespace WebCore |
OLD | NEW |