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 BorderEdge_h | 5 #ifndef BorderEdge_h |
6 #define BorderEdge_h | 6 #define BorderEdge_h |
7 | 7 |
8 #include "core/style/ComputedStyleConstants.h" | 8 #include "core/style/ComputedStyleConstants.h" |
9 #include "platform/graphics/Color.h" | 9 #include "platform/graphics/Color.h" |
| 10 #include "wtf/Allocator.h" |
10 | 11 |
11 namespace blink { | 12 namespace blink { |
12 | 13 |
13 struct BorderEdge { | 14 struct BorderEdge { |
| 15 STACK_ALLOCATED(); |
| 16 public: |
14 BorderEdge(int edgeWidth, const Color& edgeColor, EBorderStyle edgeStyle, bo
ol edgeIsPresent = true); | 17 BorderEdge(int edgeWidth, const Color& edgeColor, EBorderStyle edgeStyle, bo
ol edgeIsPresent = true); |
15 BorderEdge(); | 18 BorderEdge(); |
16 | 19 |
17 bool hasVisibleColorAndStyle() const; | 20 bool hasVisibleColorAndStyle() const; |
18 bool shouldRender() const; | 21 bool shouldRender() const; |
19 bool presentButInvisible() const; | 22 bool presentButInvisible() const; |
20 bool obscuresBackgroundEdge() const; | 23 bool obscuresBackgroundEdge() const; |
21 bool obscuresBackground() const; | 24 bool obscuresBackground() const; |
22 int usedWidth() const; | 25 int usedWidth() const; |
23 | 26 |
(...skipping 12 matching lines...) Expand all Loading... |
36 Color color; | 39 Color color; |
37 bool isPresent; | 40 bool isPresent; |
38 | 41 |
39 private: | 42 private: |
40 unsigned style: 4; // EBorderStyle | 43 unsigned style: 4; // EBorderStyle |
41 }; | 44 }; |
42 | 45 |
43 } // namespace blink | 46 } // namespace blink |
44 | 47 |
45 #endif // BorderEdge_h | 48 #endif // BorderEdge_h |
OLD | NEW |