| 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 24 matching lines...) Expand all Loading... |
| 35 #include "core/svg/properties/SVGPropertyTearOff.h" | 35 #include "core/svg/properties/SVGPropertyTearOff.h" |
| 36 #include "platform/bindings/ScriptWrappable.h" | 36 #include "platform/bindings/ScriptWrappable.h" |
| 37 | 37 |
| 38 namespace blink { | 38 namespace blink { |
| 39 | 39 |
| 40 class SVGNumberTearOff : public SVGPropertyTearOff<SVGNumber>, | 40 class SVGNumberTearOff : public SVGPropertyTearOff<SVGNumber>, |
| 41 public ScriptWrappable { | 41 public ScriptWrappable { |
| 42 DEFINE_WRAPPERTYPEINFO(); | 42 DEFINE_WRAPPERTYPEINFO(); |
| 43 | 43 |
| 44 public: | 44 public: |
| 45 static SVGNumberTearOff* Create( | 45 static SVGNumberTearOff* Create(SVGNumber* target, |
| 46 SVGNumber* target, | 46 SVGElement* context_element, |
| 47 SVGElement* context_element, | 47 PropertyIsAnimValType property_is_anim_val, |
| 48 PropertyIsAnimValType property_is_anim_val, | 48 const QualifiedName& attribute_name) { |
| 49 const QualifiedName& attribute_name = QualifiedName::Null()) { | |
| 50 return new SVGNumberTearOff(target, context_element, property_is_anim_val, | 49 return new SVGNumberTearOff(target, context_element, property_is_anim_val, |
| 51 attribute_name); | 50 attribute_name); |
| 52 } | 51 } |
| 52 static SVGNumberTearOff* CreateDetached(); |
| 53 | 53 |
| 54 DECLARE_VIRTUAL_TRACE_WRAPPERS(); | 54 DECLARE_VIRTUAL_TRACE_WRAPPERS(); |
| 55 | 55 |
| 56 void setValue(float, ExceptionState&); | 56 void setValue(float, ExceptionState&); |
| 57 float value() { return Target()->Value(); } | 57 float value() { return Target()->Value(); } |
| 58 | 58 |
| 59 protected: | 59 protected: |
| 60 SVGNumberTearOff(SVGNumber*, | 60 SVGNumberTearOff(SVGNumber*, |
| 61 SVGElement* context_element, | 61 SVGElement* context_element, |
| 62 PropertyIsAnimValType, | 62 PropertyIsAnimValType, |
| 63 const QualifiedName& attribute_name = QualifiedName::Null()); | 63 const QualifiedName& attribute_name); |
| 64 }; | 64 }; |
| 65 | 65 |
| 66 } // namespace blink | 66 } // namespace blink |
| 67 | 67 |
| 68 #endif // SVGNumberTearOff_h | 68 #endif // SVGNumberTearOff_h |
| OLD | NEW |