OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2014 Google Inc. All rights reserved. | 2 * Copyright (C) 2014 Google Inc. 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 are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 , m_contextTransform(nullptr) | 42 , m_contextTransform(nullptr) |
43 { | 43 { |
44 } | 44 } |
45 | 45 |
46 SVGMatrixTearOff::SVGMatrixTearOff(SVGTransformTearOff* transform) | 46 SVGMatrixTearOff::SVGMatrixTearOff(SVGTransformTearOff* transform) |
47 : m_contextTransform(transform) | 47 : m_contextTransform(transform) |
48 { | 48 { |
49 ASSERT(transform); | 49 ASSERT(transform); |
50 } | 50 } |
51 | 51 |
| 52 SVGMatrixTearOff::~SVGMatrixTearOff() |
| 53 { |
| 54 } |
| 55 |
52 DEFINE_TRACE(SVGMatrixTearOff) | 56 DEFINE_TRACE(SVGMatrixTearOff) |
53 { | 57 { |
54 visitor->trace(m_contextTransform); | 58 visitor->trace(m_contextTransform); |
55 } | 59 } |
56 | 60 |
57 const AffineTransform& SVGMatrixTearOff::value() const | 61 const AffineTransform& SVGMatrixTearOff::value() const |
58 { | 62 { |
59 return m_contextTransform ? m_contextTransform->target()->matrix() : m_stati
cValue; | 63 return m_contextTransform ? m_contextTransform->target()->matrix() : m_stati
cValue; |
60 } | 64 } |
61 | 65 |
(...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
169 { | 173 { |
170 if (!x || !y) | 174 if (!x || !y) |
171 exceptionState.throwDOMException(InvalidAccessError, "Arguments cannot b
e zero."); | 175 exceptionState.throwDOMException(InvalidAccessError, "Arguments cannot b
e zero."); |
172 | 176 |
173 AffineTransform copy = value(); | 177 AffineTransform copy = value(); |
174 copy.rotateFromVector(x, y); | 178 copy.rotateFromVector(x, y); |
175 return create(copy); | 179 return create(copy); |
176 } | 180 } |
177 | 181 |
178 } // namespace blink | 182 } // namespace blink |
OLD | NEW |