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 #ifndef FloatClipDisplayItem_h | 5 #ifndef FloatClipDisplayItem_h |
6 #define FloatClipDisplayItem_h | 6 #define FloatClipDisplayItem_h |
7 | 7 |
8 #include "platform/PlatformExport.h" | 8 #include "platform/PlatformExport.h" |
9 #include "platform/geometry/FloatRect.h" | 9 #include "platform/geometry/FloatRect.h" |
10 #include "platform/graphics/paint/DisplayItem.h" | 10 #include "platform/graphics/paint/DisplayItem.h" |
11 | 11 |
12 namespace blink { | 12 namespace blink { |
13 | 13 |
14 class RoundedRect; | |
15 | |
16 class PLATFORM_EXPORT FloatClipDisplayItem final | 14 class PLATFORM_EXPORT FloatClipDisplayItem final |
17 : public PairedBeginDisplayItem { | 15 : public PairedBeginDisplayItem { |
18 public: | 16 public: |
19 FloatClipDisplayItem(const DisplayItemClient& client, | 17 FloatClipDisplayItem(const DisplayItemClient& client, |
20 Type type, | 18 Type type, |
21 const FloatRect& clipRect) | 19 const FloatRect& clipRect) |
22 : PairedBeginDisplayItem(client, type, sizeof(*this)), | 20 : PairedBeginDisplayItem(client, type, sizeof(*this)), |
23 m_clipRect(clipRect) { | 21 m_clipRect(clipRect) { |
24 ASSERT(isFloatClipType(type)); | 22 ASSERT(isFloatClipType(type)); |
25 } | 23 } |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 #if ENABLE(ASSERT) | 55 #if ENABLE(ASSERT) |
58 bool isEndAndPairedWith(DisplayItem::Type otherType) const final { | 56 bool isEndAndPairedWith(DisplayItem::Type otherType) const final { |
59 return DisplayItem::isFloatClipType(otherType); | 57 return DisplayItem::isFloatClipType(otherType); |
60 } | 58 } |
61 #endif | 59 #endif |
62 }; | 60 }; |
63 | 61 |
64 } // namespace blink | 62 } // namespace blink |
65 | 63 |
66 #endif // FloatClipDisplayItem_h | 64 #endif // FloatClipDisplayItem_h |
OLD | NEW |