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

Unified Diff: third_party/WebKit/Source/core/paint/PaintInfoTest.cpp

Issue 1647313003: Continue converting to explicit LayoutUnit constructors (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@explicitContstructors
Patch Set: Add TODO Created 4 years, 11 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
Index: third_party/WebKit/Source/core/paint/PaintInfoTest.cpp
diff --git a/third_party/WebKit/Source/core/paint/PaintInfoTest.cpp b/third_party/WebKit/Source/core/paint/PaintInfoTest.cpp
index 1c9f076e062a9b147703e0af9f3f5ff11d825203..0ade3a245ce4d3af85877020c2d0fdcd1e08aa15 100644
--- a/third_party/WebKit/Source/core/paint/PaintInfoTest.cpp
+++ b/third_party/WebKit/Source/core/paint/PaintInfoTest.cpp
@@ -33,7 +33,7 @@ TEST_F(PaintInfoTest, intersectsCullRectWithLayoutRect)
PaintInfo paintInfo(m_context, IntRect(0, 0, 50, 50), PaintPhaseSelfBlockBackgroundOnly, GlobalPaintNormalPhase, PaintLayerNoFlag);
EXPECT_TRUE(paintInfo.cullRect().intersectsCullRect(LayoutRect(0, 0, 1, 1)));
- EXPECT_TRUE(paintInfo.cullRect().intersectsCullRect(LayoutRect(0.1, 0.1, 0.1, 0.1)));
+ EXPECT_TRUE(paintInfo.cullRect().intersectsCullRect(LayoutRect(LayoutUnit(0.1), LayoutUnit(0.1), LayoutUnit(0.1), LayoutUnit(0.1))));
}
TEST_F(PaintInfoTest, intersectsCullRectWithTransform)
@@ -61,16 +61,16 @@ TEST_F(PaintInfoTest, intersectsVerticalRange)
{
PaintInfo paintInfo(m_context, IntRect(0, 0, 50, 100), PaintPhaseSelfBlockBackgroundOnly, GlobalPaintNormalPhase, PaintLayerNoFlag);
- EXPECT_TRUE(paintInfo.cullRect().intersectsVerticalRange(0, 1));
- EXPECT_FALSE(paintInfo.cullRect().intersectsVerticalRange(100, 101));
+ EXPECT_TRUE(paintInfo.cullRect().intersectsVerticalRange(LayoutUnit(0), LayoutUnit(1)));
+ EXPECT_FALSE(paintInfo.cullRect().intersectsVerticalRange(LayoutUnit(100), LayoutUnit(101)));
}
TEST_F(PaintInfoTest, intersectsHorizontalRange)
{
PaintInfo paintInfo(m_context, IntRect(0, 0, 50, 100), PaintPhaseSelfBlockBackgroundOnly, GlobalPaintNormalPhase, PaintLayerNoFlag);
- EXPECT_TRUE(paintInfo.cullRect().intersectsHorizontalRange(0, 1));
- EXPECT_FALSE(paintInfo.cullRect().intersectsHorizontalRange(50, 51));
+ EXPECT_TRUE(paintInfo.cullRect().intersectsHorizontalRange(LayoutUnit(0), LayoutUnit(1)));
+ EXPECT_FALSE(paintInfo.cullRect().intersectsHorizontalRange(LayoutUnit(50), LayoutUnit(51)));
}
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/core/paint/NinePieceImageGrid.cpp ('k') | third_party/WebKit/Source/platform/LayoutUnit.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698