| Index: Source/core/svg/SVGTransformTearOff.h
|
| diff --git a/Source/core/svg/SVGPointListTearOff.h b/Source/core/svg/SVGTransformTearOff.h
|
| similarity index 50%
|
| copy from Source/core/svg/SVGPointListTearOff.h
|
| copy to Source/core/svg/SVGTransformTearOff.h
|
| index c7a6319b327559ba5e39c6b725ebc8946b6bc677..9ea0ba16ad833a7862561f5b0ca333e06f481465 100644
|
| --- a/Source/core/svg/SVGPointListTearOff.h
|
| +++ b/Source/core/svg/SVGTransformTearOff.h
|
| @@ -28,31 +28,54 @@
|
| * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
| */
|
|
|
| -#ifndef SVGPointListTearOff_h
|
| -#define SVGPointListTearOff_h
|
| +#ifndef SVGTransformTearOff_h
|
| +#define SVGTransformTearOff_h
|
|
|
| -#include "core/svg/SVGPointList.h"
|
| -#include "core/svg/properties/NewSVGListPropertyTearOffHelper.h"
|
| +#include "bindings/v8/ScriptWrappable.h"
|
| +#include "core/svg/SVGMatrixTearOff.h"
|
| +#include "core/svg/SVGTransform.h"
|
| +#include "core/svg/properties/NewSVGPropertyTearOff.h"
|
|
|
| namespace WebCore {
|
|
|
| -class SVGPointListTearOff FINAL :
|
| - public NewSVGListPropertyTearOffHelper<SVGPointListTearOff, SVGPointList>,
|
| - public ScriptWrappable {
|
| +class SVGMatrix;
|
| +
|
| +class SVGTransformTearOff FINAL : public NewSVGPropertyTearOff<SVGTransform>, public ScriptWrappable {
|
| public:
|
| - static PassRefPtr<SVGPointListTearOff> create(PassRefPtr<SVGPointList> target, SVGElement* contextElement, PropertyIsAnimValType propertyIsAnimVal, const QualifiedName& attributeName = nullQName())
|
| + enum SVGTransformType {
|
| + SVG_TRANSFORM_UNKNOWN = WebCore::SVG_TRANSFORM_UNKNOWN,
|
| + SVG_TRANSFORM_MATRIX = WebCore::SVG_TRANSFORM_MATRIX,
|
| + SVG_TRANSFORM_TRANSLATE = WebCore::SVG_TRANSFORM_TRANSLATE,
|
| + SVG_TRANSFORM_SCALE = WebCore::SVG_TRANSFORM_SCALE,
|
| + SVG_TRANSFORM_ROTATE = WebCore::SVG_TRANSFORM_ROTATE,
|
| + SVG_TRANSFORM_SKEWX = WebCore::SVG_TRANSFORM_SKEWX,
|
| + SVG_TRANSFORM_SKEWY = WebCore::SVG_TRANSFORM_SKEWY,
|
| + };
|
| +
|
| + static PassRefPtr<SVGTransformTearOff> create(PassRefPtr<SVGTransform> target, SVGElement* contextElement, PropertyIsAnimValType propertyIsAnimVal, const QualifiedName& attributeName = nullQName())
|
| {
|
| - return adoptRef(new SVGPointListTearOff(target, contextElement, propertyIsAnimVal, attributeName));
|
| + return adoptRef(new SVGTransformTearOff(target, contextElement, propertyIsAnimVal, attributeName));
|
| }
|
|
|
| + virtual ~SVGTransformTearOff();
|
| +
|
| + unsigned short transformType() { return target()->transformType(); }
|
| + SVGMatrixTearOff* matrix();
|
| + float angle() { return target()->angle(); }
|
| +
|
| + void setMatrix(PassRefPtr<SVGMatrixTearOff>, ExceptionState&);
|
| + void setTranslate(float tx, float ty, ExceptionState&);
|
| + void setScale(float sx, float sy, ExceptionState&);
|
| + void setRotate(float angle, float cx, float cy, ExceptionState&);
|
| + void setSkewX(float, ExceptionState&);
|
| + void setSkewY(float, ExceptionState&);
|
| +
|
| private:
|
| - SVGPointListTearOff(PassRefPtr<SVGPointList> target, SVGElement* contextElement, PropertyIsAnimValType propertyIsAnimVal, const QualifiedName& attributeName = nullQName())
|
| - : NewSVGListPropertyTearOffHelper<SVGPointListTearOff, SVGPointList>(target, contextElement, propertyIsAnimVal, attributeName)
|
| - {
|
| - ScriptWrappable::init(this);
|
| - }
|
| + SVGTransformTearOff(PassRefPtr<SVGTransform>, SVGElement* contextElement, PropertyIsAnimValType, const QualifiedName& attributeName);
|
| +
|
| + RefPtr<SVGMatrixTearOff> m_matrixTearoff;
|
| };
|
|
|
| } // namespace WebCore
|
|
|
| -#endif // SVGPointListTearOff_h_
|
| +#endif // SVGTransformTearOff_h_
|
|
|