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

Side by Side Diff: third_party/WebKit/Source/core/paint/PaintLayer.cpp

Issue 2318243002: Promote opaque fixed position elements. (Closed)
Patch Set: Use ScopedRuntimeEnabledFeatureForTest. Created 4 years, 2 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) 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 2430 matching lines...) Expand 10 before | Expand all | Expand 10 after
2441 2441
2442 // We can't use hasVisibleContent(), because that will be true if our layout Object is hidden, but some child 2442 // We can't use hasVisibleContent(), because that will be true if our layout Object is hidden, but some child
2443 // is visible and that child doesn't cover the entire rect. 2443 // is visible and that child doesn't cover the entire rect.
2444 if (layoutObject()->style()->visibility() != EVisibility::Visible) 2444 if (layoutObject()->style()->visibility() != EVisibility::Visible)
2445 return false; 2445 return false;
2446 2446
2447 if (paintsWithFilters() && layoutObject()->style()->filter().hasFilterThatAf fectsOpacity()) 2447 if (paintsWithFilters() && layoutObject()->style()->filter().hasFilterThatAf fectsOpacity())
2448 return false; 2448 return false;
2449 2449
2450 // FIXME: Handle simple transforms. 2450 // FIXME: Handle simple transforms.
2451 if (paintsWithTransform(GlobalPaintNormalPhase)) 2451 if (transform() && compositingState() != PaintsIntoOwnBacking)
2452 return false;
2453
2454 if (!RuntimeEnabledFeatures::compositeOpaqueFixedPositionEnabled()
2455 && layoutObject()->style()->position() == FixedPosition
2456 && compositingState() != PaintsIntoOwnBacking)
2452 return false; 2457 return false;
2453 2458
2454 // This function should not be called when layer-lists are dirty. 2459 // This function should not be called when layer-lists are dirty.
2455 // TODO(schenney) This check never hits in layout tests or most platforms, b ut does hit in 2460 // TODO(schenney) This check never hits in layout tests or most platforms, b ut does hit in
2456 // PopupBlockerBrowserTest.AllowPopupThroughContentSetting on Win 7 Test Bui lder. 2461 // PopupBlockerBrowserTest.AllowPopupThroughContentSetting on Win 7 Test Bui lder.
2457 if (m_stackingNode->zOrderListsDirty()) 2462 if (m_stackingNode->zOrderListsDirty())
2458 return false; 2463 return false;
2459 2464
2460 // FIXME: We currently only check the immediate layoutObject, 2465 // FIXME: We currently only check the immediate layoutObject,
2461 // which will miss many cases where additional layout objects paint 2466 // which will miss many cases where additional layout objects paint
(...skipping 519 matching lines...) Expand 10 before | Expand all | Expand 10 after
2981 2986
2982 void showLayerTree(const blink::LayoutObject* layoutObject) 2987 void showLayerTree(const blink::LayoutObject* layoutObject)
2983 { 2988 {
2984 if (!layoutObject) { 2989 if (!layoutObject) {
2985 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n"); 2990 fprintf(stderr, "Cannot showLayerTree. Root is (nil)\n");
2986 return; 2991 return;
2987 } 2992 }
2988 showLayerTree(layoutObject->enclosingLayer()); 2993 showLayerTree(layoutObject->enclosingLayer());
2989 } 2994 }
2990 #endif 2995 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698