OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 2 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above | 8 * 1. Redistributions of source code must retain the above |
9 * copyright notice, this list of conditions and the following | 9 * copyright notice, this list of conditions and the following |
10 * disclaimer. | 10 * disclaimer. |
(...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
90 x1 = std::min<float>(x1, minXIntercept); | 90 x1 = std::min<float>(x1, minXIntercept); |
91 x2 = std::max<float>(x2, maxXIntercept); | 91 x2 = std::max<float>(x2, maxXIntercept); |
92 } | 92 } |
93 | 93 |
94 ASSERT(x2 >= x1); | 94 ASSERT(x2 >= x1); |
95 return LineSegment(x1, x2); | 95 return LineSegment(x1, x2); |
96 } | 96 } |
97 | 97 |
98 void BoxShape::buildDisplayPaths(DisplayPaths& paths) const | 98 void BoxShape::buildDisplayPaths(DisplayPaths& paths) const |
99 { | 99 { |
100 paths.shape.addRoundedRect(m_bounds.rect(), m_bounds.radii().topLeft(), m_bo
unds.radii().topRight(), m_bounds.radii().bottomLeft(), m_bounds.radii().bottomR
ight()); | 100 paths.shape.addRoundedRect(m_bounds.rect(), m_bounds.getRadii().topLeft(), m
_bounds.getRadii().topRight(), m_bounds.getRadii().bottomLeft(), m_bounds.getRad
ii().bottomRight()); |
101 if (shapeMargin()) | 101 if (shapeMargin()) |
102 paths.marginShape.addRoundedRect(shapeMarginBounds().rect(), shapeMargin
Bounds().radii().topLeft(), shapeMarginBounds().radii().topRight(), shapeMarginB
ounds().radii().bottomLeft(), shapeMarginBounds().radii().bottomRight()); | 102 paths.marginShape.addRoundedRect(shapeMarginBounds().rect(), shapeMargin
Bounds().getRadii().topLeft(), shapeMarginBounds().getRadii().topRight(), shapeM
arginBounds().getRadii().bottomLeft(), shapeMarginBounds().getRadii().bottomRigh
t()); |
103 } | 103 } |
104 | 104 |
105 } // namespace blink | 105 } // namespace blink |
OLD | NEW |