OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "core/paint/PaintInfo.h" | 5 #include "core/paint/PaintInfo.h" |
6 | 6 |
| 7 #include <memory> |
7 #include "platform/graphics/paint/PaintController.h" | 8 #include "platform/graphics/paint/PaintController.h" |
8 #include "testing/gtest/include/gtest/gtest.h" | 9 #include "testing/gtest/include/gtest/gtest.h" |
9 #include <memory> | |
10 | 10 |
11 namespace blink { | 11 namespace blink { |
12 | 12 |
13 class PaintInfoTest : public testing::Test { | 13 class PaintInfoTest : public testing::Test { |
14 protected: | 14 protected: |
15 PaintInfoTest() | 15 PaintInfoTest() |
16 : m_paintController(PaintController::create()), | 16 : m_paintController(PaintController::create()), |
17 m_context(*m_paintController) {} | 17 m_context(*m_paintController) {} |
18 | 18 |
19 std::unique_ptr<PaintController> m_paintController; | 19 std::unique_ptr<PaintController> m_paintController; |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
79 PaintPhaseSelfBlockBackgroundOnly, GlobalPaintNormalPhase, | 79 PaintPhaseSelfBlockBackgroundOnly, GlobalPaintNormalPhase, |
80 PaintLayerNoFlag); | 80 PaintLayerNoFlag); |
81 | 81 |
82 EXPECT_TRUE(paintInfo.cullRect().intersectsHorizontalRange(LayoutUnit(), | 82 EXPECT_TRUE(paintInfo.cullRect().intersectsHorizontalRange(LayoutUnit(), |
83 LayoutUnit(1))); | 83 LayoutUnit(1))); |
84 EXPECT_FALSE(paintInfo.cullRect().intersectsHorizontalRange(LayoutUnit(50), | 84 EXPECT_FALSE(paintInfo.cullRect().intersectsHorizontalRange(LayoutUnit(50), |
85 LayoutUnit(51))); | 85 LayoutUnit(51))); |
86 } | 86 } |
87 | 87 |
88 } // namespace blink | 88 } // namespace blink |
OLD | NEW |