OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 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 13 matching lines...) Expand all Loading... |
24 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | 24 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 25 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
29 */ | 29 */ |
30 | 30 |
31 #include "config.h" | 31 #include "config.h" |
32 #include "bindings/core/v8/V8SVGPathSeg.h" | 32 #include "bindings/core/v8/V8SVGPathSeg.h" |
33 | 33 |
| 34 #include "bindings/core/v8/V8DOMWrapper.h" |
34 #include "bindings/core/v8/V8SVGPathSegArcAbs.h" | 35 #include "bindings/core/v8/V8SVGPathSegArcAbs.h" |
35 #include "bindings/core/v8/V8SVGPathSegArcRel.h" | 36 #include "bindings/core/v8/V8SVGPathSegArcRel.h" |
36 #include "bindings/core/v8/V8SVGPathSegClosePath.h" | 37 #include "bindings/core/v8/V8SVGPathSegClosePath.h" |
37 #include "bindings/core/v8/V8SVGPathSegCurvetoCubicAbs.h" | 38 #include "bindings/core/v8/V8SVGPathSegCurvetoCubicAbs.h" |
38 #include "bindings/core/v8/V8SVGPathSegCurvetoCubicRel.h" | 39 #include "bindings/core/v8/V8SVGPathSegCurvetoCubicRel.h" |
39 #include "bindings/core/v8/V8SVGPathSegCurvetoCubicSmoothAbs.h" | 40 #include "bindings/core/v8/V8SVGPathSegCurvetoCubicSmoothAbs.h" |
40 #include "bindings/core/v8/V8SVGPathSegCurvetoCubicSmoothRel.h" | 41 #include "bindings/core/v8/V8SVGPathSegCurvetoCubicSmoothRel.h" |
41 #include "bindings/core/v8/V8SVGPathSegCurvetoQuadraticAbs.h" | 42 #include "bindings/core/v8/V8SVGPathSegCurvetoQuadraticAbs.h" |
42 #include "bindings/core/v8/V8SVGPathSegCurvetoQuadraticRel.h" | 43 #include "bindings/core/v8/V8SVGPathSegCurvetoQuadraticRel.h" |
43 #include "bindings/core/v8/V8SVGPathSegCurvetoQuadraticSmoothAbs.h" | 44 #include "bindings/core/v8/V8SVGPathSegCurvetoQuadraticSmoothAbs.h" |
44 #include "bindings/core/v8/V8SVGPathSegCurvetoQuadraticSmoothRel.h" | 45 #include "bindings/core/v8/V8SVGPathSegCurvetoQuadraticSmoothRel.h" |
45 #include "bindings/core/v8/V8SVGPathSegLinetoAbs.h" | 46 #include "bindings/core/v8/V8SVGPathSegLinetoAbs.h" |
46 #include "bindings/core/v8/V8SVGPathSegLinetoHorizontalAbs.h" | 47 #include "bindings/core/v8/V8SVGPathSegLinetoHorizontalAbs.h" |
47 #include "bindings/core/v8/V8SVGPathSegLinetoHorizontalRel.h" | 48 #include "bindings/core/v8/V8SVGPathSegLinetoHorizontalRel.h" |
48 #include "bindings/core/v8/V8SVGPathSegLinetoRel.h" | 49 #include "bindings/core/v8/V8SVGPathSegLinetoRel.h" |
49 #include "bindings/core/v8/V8SVGPathSegLinetoVerticalAbs.h" | 50 #include "bindings/core/v8/V8SVGPathSegLinetoVerticalAbs.h" |
50 #include "bindings/core/v8/V8SVGPathSegLinetoVerticalRel.h" | 51 #include "bindings/core/v8/V8SVGPathSegLinetoVerticalRel.h" |
51 #include "bindings/core/v8/V8SVGPathSegMovetoAbs.h" | 52 #include "bindings/core/v8/V8SVGPathSegMovetoAbs.h" |
52 #include "bindings/core/v8/V8SVGPathSegMovetoRel.h" | 53 #include "bindings/core/v8/V8SVGPathSegMovetoRel.h" |
53 #include "bindings/core/v8/V8Window.h" | 54 #include "bindings/core/v8/V8Window.h" |
54 #include "bindings/v8/V8DOMWrapper.h" | |
55 | 55 |
56 namespace WebCore { | 56 namespace WebCore { |
57 | 57 |
58 v8::Handle<v8::Object> wrap(SVGPathSeg* impl, v8::Handle<v8::Object> creationCon
text, v8::Isolate* isolate) | 58 v8::Handle<v8::Object> wrap(SVGPathSeg* impl, v8::Handle<v8::Object> creationCon
text, v8::Isolate* isolate) |
59 { | 59 { |
60 ASSERT(impl); | 60 ASSERT(impl); |
61 switch (impl->pathSegType()) { | 61 switch (impl->pathSegType()) { |
62 case SVGPathSeg::PATHSEG_CLOSEPATH: | 62 case SVGPathSeg::PATHSEG_CLOSEPATH: |
63 return wrap(static_cast<SVGPathSegClosePath*>(impl), creationContext, is
olate); | 63 return wrap(static_cast<SVGPathSegClosePath*>(impl), creationContext, is
olate); |
64 case SVGPathSeg::PATHSEG_MOVETO_ABS: | 64 case SVGPathSeg::PATHSEG_MOVETO_ABS: |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 case SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: | 96 case SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_SMOOTH_ABS: |
97 return wrap(static_cast<SVGPathSegCurvetoQuadraticSmoothAbs*>(impl), cre
ationContext, isolate); | 97 return wrap(static_cast<SVGPathSegCurvetoQuadraticSmoothAbs*>(impl), cre
ationContext, isolate); |
98 case SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: | 98 case SVGPathSeg::PATHSEG_CURVETO_QUADRATIC_SMOOTH_REL: |
99 return wrap(static_cast<SVGPathSegCurvetoQuadraticSmoothRel*>(impl), cre
ationContext, isolate); | 99 return wrap(static_cast<SVGPathSegCurvetoQuadraticSmoothRel*>(impl), cre
ationContext, isolate); |
100 } | 100 } |
101 ASSERT_NOT_REACHED(); | 101 ASSERT_NOT_REACHED(); |
102 return V8SVGPathSeg::createWrapper(impl, creationContext, isolate); | 102 return V8SVGPathSeg::createWrapper(impl, creationContext, isolate); |
103 } | 103 } |
104 | 104 |
105 } // namespace WebCore | 105 } // namespace WebCore |
OLD | NEW |