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

Side by Side Diff: Source/core/paint/DeprecatedPaintLayerPainterTest.cpp

Issue 1246173002: Throttle rendering pipeline for invisible iframes (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add layout tests. Created 5 years, 3 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 6
7 #include "core/paint/DisplayItemListPaintTest.h" 7 #include "core/paint/DisplayItemListPaintTest.h"
8 #include "platform/graphics/GraphicsContext.h" 8 #include "platform/graphics/GraphicsContext.h"
9 9
10 namespace blink { 10 namespace blink {
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 113
114 DeprecatedPaintLayer& rootLayer = *layoutView().layer(); 114 DeprecatedPaintLayer& rootLayer = *layoutView().layer();
115 DeprecatedPaintLayer& htmlLayer = *toLayoutBoxModelObject(document().documen tElement()->layoutObject())->layer(); 115 DeprecatedPaintLayer& htmlLayer = *toLayoutBoxModelObject(document().documen tElement()->layoutObject())->layer();
116 LayoutObject& container1 = *document().getElementById("container1")->layoutO bject(); 116 LayoutObject& container1 = *document().getElementById("container1")->layoutO bject();
117 DeprecatedPaintLayer& container1Layer = *toLayoutBoxModelObject(container1). layer(); 117 DeprecatedPaintLayer& container1Layer = *toLayoutBoxModelObject(container1). layer();
118 LayoutObject& container2 = *document().getElementById("container2")->layoutO bject(); 118 LayoutObject& container2 = *document().getElementById("container2")->layoutO bject();
119 DeprecatedPaintLayer& container2Layer = *toLayoutBoxModelObject(container2). layer(); 119 DeprecatedPaintLayer& container2Layer = *toLayoutBoxModelObject(container2). layer();
120 LayoutObject& container3 = *document().getElementById("container3")->layoutO bject(); 120 LayoutObject& container3 = *document().getElementById("container3")->layoutO bject();
121 DeprecatedPaintLayer& container3Layer = *toLayoutBoxModelObject(container3). layer(); 121 DeprecatedPaintLayer& container3Layer = *toLayoutBoxModelObject(container3). layer();
122 122
123 document().view()->updateAllLifecyclePhases(LayoutRect(0, 0, 400, 300)); 123 document().view()->updateAllLifecyclePhases(DocumentLifecycle::ThrottlingMod e::Disallow, LayoutRect(0, 0, 400, 300));
124 124
125 // Container1 is fully in the interest rect; 125 // Container1 is fully in the interest rect;
126 // Container2 is partly (including its stacking chidren) in the interest rec t; 126 // Container2 is partly (including its stacking chidren) in the interest rec t;
127 // Content2 is out of the interest rect and output nothing; 127 // Content2 is out of the interest rect and output nothing;
128 // Container3 is fully in the interest rect. 128 // Container3 is fully in the interest rect.
129 EXPECT_DISPLAY_LIST(rootDisplayItemList().displayItems(), 14, 129 EXPECT_DISPLAY_LIST(rootDisplayItemList().displayItems(), 14,
130 TestDisplayItem(rootLayer, DisplayItem::BeginSubsequence), 130 TestDisplayItem(rootLayer, DisplayItem::BeginSubsequence),
131 TestDisplayItem(layoutView(), DisplayItem::BoxDecorationBackground), 131 TestDisplayItem(layoutView(), DisplayItem::BoxDecorationBackground),
132 TestDisplayItem(htmlLayer, DisplayItem::BeginSubsequence), 132 TestDisplayItem(htmlLayer, DisplayItem::BeginSubsequence),
133 TestDisplayItem(container1Layer, DisplayItem::BeginSubsequence), 133 TestDisplayItem(container1Layer, DisplayItem::BeginSubsequence),
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 TestDisplayItem(container1, DisplayItem::BoxDecorationBackground), 170 TestDisplayItem(container1, DisplayItem::BoxDecorationBackground),
171 TestDisplayItem(container1Layer, DisplayItem::EndSubsequence), 171 TestDisplayItem(container1Layer, DisplayItem::EndSubsequence),
172 TestDisplayItem(container2Layer, DisplayItem::BeginSubsequence), 172 TestDisplayItem(container2Layer, DisplayItem::BeginSubsequence),
173 TestDisplayItem(container2, DisplayItem::BoxDecorationBackground), 173 TestDisplayItem(container2, DisplayItem::BoxDecorationBackground),
174 TestDisplayItem(container2Layer, DisplayItem::EndSubsequence), 174 TestDisplayItem(container2Layer, DisplayItem::EndSubsequence),
175 TestDisplayItem(htmlLayer, DisplayItem::EndSubsequence), 175 TestDisplayItem(htmlLayer, DisplayItem::EndSubsequence),
176 TestDisplayItem(rootLayer, DisplayItem::EndSubsequence)); 176 TestDisplayItem(rootLayer, DisplayItem::EndSubsequence));
177 } 177 }
178 178
179 } // namespace blink 179 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698