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

Unified Diff: Source/core/paint/DeprecatedPaintLayerPainter.cpp

Issue 1297803002: Remove FOUC avoidance from BlockPainter and DeprecatedPaintLayerPainter. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Remove extra assert. Created 5 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/paint/BlockPainter.cpp ('k') | Source/core/testing/Internals.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/paint/DeprecatedPaintLayerPainter.cpp
diff --git a/Source/core/paint/DeprecatedPaintLayerPainter.cpp b/Source/core/paint/DeprecatedPaintLayerPainter.cpp
index dd5c832349eff691dbe899aefe94b446eea0190b..0189a23964b97d5caf2de2047ca11dfb5cce392e 100644
--- a/Source/core/paint/DeprecatedPaintLayerPainter.cpp
+++ b/Source/core/paint/DeprecatedPaintLayerPainter.cpp
@@ -31,17 +31,6 @@
namespace blink {
-static inline bool shouldSuppressPaintingLayer(DeprecatedPaintLayer* layer)
-{
- // Avoid painting descendants of the root layer when stylesheets haven't loaded. This eliminates FOUC.
- // It's ok not to draw, because later on, when all the stylesheets do load, updateStyleSelector on the Document
- // will do a full paintInvalidationForWholeLayoutObject().
- if (layer->layoutObject()->document().didLayoutWithPendingStylesheets() && !layer->isRootLayer() && !layer->layoutObject()->isDocumentElement())
- return true;
-
- return false;
-}
-
void DeprecatedPaintLayerPainter::paint(GraphicsContext* context, const LayoutRect& damageRect, const GlobalPaintFlags globalPaintFlags, LayoutObject* paintingRoot, PaintLayerFlags paintFlags)
{
DeprecatedPaintLayerPaintingInfo paintingInfo(&m_paintLayer, LayoutRect(enclosingIntRect(damageRect)), globalPaintFlags, LayoutSize(), paintingRoot);
@@ -71,9 +60,6 @@ void DeprecatedPaintLayerPainter::paintLayer(GraphicsContext* context, const Dep
if (!m_paintLayer.isSelfPaintingLayer() && !m_paintLayer.hasSelfPaintingLayerDescendant())
return;
- if (shouldSuppressPaintingLayer(&m_paintLayer))
- return;
-
// If this layer is totally invisible then there is nothing to paint.
if (!m_paintLayer.layoutObject()->opacity())
return;
« no previous file with comments | « Source/core/paint/BlockPainter.cpp ('k') | Source/core/testing/Internals.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698