OLD | NEW |
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 #ifndef RoundedInnerRectClipper_h | 5 #ifndef RoundedInnerRectClipper_h |
6 #define RoundedInnerRectClipper_h | 6 #define RoundedInnerRectClipper_h |
7 | 7 |
8 #include "platform/graphics/paint/DisplayItem.h" | 8 #include "platform/graphics/paint/DisplayItem.h" |
9 #include "wtf/Allocator.h" | 9 #include "wtf/Allocator.h" |
10 | 10 |
11 namespace blink { | 11 namespace blink { |
12 | 12 |
13 class FloatRoundedRect; | 13 class FloatRoundedRect; |
14 class LayoutRect; | 14 class LayoutRect; |
15 class LayoutObject; | 15 class LayoutObject; |
16 struct PaintInfo; | 16 struct PaintInfo; |
17 | 17 |
18 enum RoundedInnerRectClipperBehavior { | 18 enum RoundedInnerRectClipperBehavior { |
19 ApplyToDisplayList, | 19 ApplyToDisplayList, |
20 ApplyToContext | 20 ApplyToContext |
21 }; | 21 }; |
22 | 22 |
23 class RoundedInnerRectClipper { | 23 class RoundedInnerRectClipper { |
24 ALLOW_ONLY_INLINE_ALLOCATION(); | 24 DISALLOW_NEW_EXCEPT_PLACEMENT_NEW(); |
25 public: | 25 public: |
26 RoundedInnerRectClipper(const LayoutObject&, const PaintInfo&, const LayoutR
ect&, const FloatRoundedRect& clipRect, RoundedInnerRectClipperBehavior); | 26 RoundedInnerRectClipper(const LayoutObject&, const PaintInfo&, const LayoutR
ect&, const FloatRoundedRect& clipRect, RoundedInnerRectClipperBehavior); |
27 ~RoundedInnerRectClipper(); | 27 ~RoundedInnerRectClipper(); |
28 | 28 |
29 private: | 29 private: |
30 const LayoutObject& m_layoutObject; | 30 const LayoutObject& m_layoutObject; |
31 const PaintInfo& m_paintInfo; | 31 const PaintInfo& m_paintInfo; |
32 bool m_usePaintController; | 32 bool m_usePaintController; |
33 DisplayItem::Type m_clipType; | 33 DisplayItem::Type m_clipType; |
34 }; | 34 }; |
35 | 35 |
36 } // namespace blink | 36 } // namespace blink |
37 | 37 |
38 #endif // RoundedInnerRectClipper_h | 38 #endif // RoundedInnerRectClipper_h |
OLD | NEW |