This source file includes following definitions.
- setX
- setY
- setWidth
- setHeight
#include "config.h"
#include "core/svg/SVGRectTearOff.h"
#include "bindings/v8/ExceptionState.h"
#include "core/dom/ExceptionCode.h"
namespace WebCore {
SVGRectTearOff::SVGRectTearOff(PassRefPtr<SVGRect> target, SVGElement* contextElement, PropertyIsAnimValType propertyIsAnimVal, const QualifiedName& attributeName)
: SVGPropertyTearOff<SVGRect>(target, contextElement, propertyIsAnimVal, attributeName)
{
ScriptWrappable::init(this);
}
void SVGRectTearOff::setX(float f, ExceptionState& exceptionState)
{
if (isImmutable()) {
exceptionState.throwDOMException(NoModificationAllowedError, "The attribute is read-only.");
return;
}
target()->setX(f);
commitChange();
}
void SVGRectTearOff::setY(float f, ExceptionState& exceptionState)
{
if (isImmutable()) {
exceptionState.throwDOMException(NoModificationAllowedError, "The attribute is read-only.");
return;
}
target()->setY(f);
commitChange();
}
void SVGRectTearOff::setWidth(float f, ExceptionState& exceptionState)
{
if (isImmutable()) {
exceptionState.throwDOMException(NoModificationAllowedError, "The attribute is read-only.");
return;
}
target()->setWidth(f);
commitChange();
}
void SVGRectTearOff::setHeight(float f, ExceptionState& exceptionState)
{
if (isImmutable()) {
exceptionState.throwDOMException(NoModificationAllowedError, "The attribute is read-only.");
return;
}
target()->setHeight(f);
commitChange();
}
}