21
21
#include "config.h"
26
#include "SVGElement.h"
27
25
#include "JSSVGPathSegLinetoHorizontalAbs.h"
29
#include <wtf/GetPtr.h>
31
27
#include "SVGPathSegLinetoHorizontal.h"
33
28
#include <runtime/JSNumberCell.h>
29
#include <wtf/GetPtr.h>
35
31
using namespace JSC;
37
33
namespace WebCore {
39
ASSERT_CLASS_FITS_IN_CELL(JSSVGPathSegLinetoHorizontalAbs)
35
ASSERT_CLASS_FITS_IN_CELL(JSSVGPathSegLinetoHorizontalAbs);
49
static const HashTable JSSVGPathSegLinetoHorizontalAbsTable =
45
static JSC_CONST_HASHTABLE HashTable JSSVGPathSegLinetoHorizontalAbsTable =
50
46
#if ENABLE(PERFECT_HASH_SIZE)
51
47
{ 0, JSSVGPathSegLinetoHorizontalAbsTableValues, 0 };
63
static const HashTable JSSVGPathSegLinetoHorizontalAbsPrototypeTable =
59
static JSC_CONST_HASHTABLE HashTable JSSVGPathSegLinetoHorizontalAbsPrototypeTable =
64
60
#if ENABLE(PERFECT_HASH_SIZE)
65
61
{ 0, JSSVGPathSegLinetoHorizontalAbsPrototypeTableValues, 0 };
77
73
const ClassInfo JSSVGPathSegLinetoHorizontalAbs::s_info = { "SVGPathSegLinetoHorizontalAbs", &JSSVGPathSeg::s_info, &JSSVGPathSegLinetoHorizontalAbsTable, 0 };
79
JSSVGPathSegLinetoHorizontalAbs::JSSVGPathSegLinetoHorizontalAbs(PassRefPtr<Structure> structure, PassRefPtr<SVGPathSegLinetoHorizontalAbs> impl, SVGElement* context)
80
: JSSVGPathSeg(structure, impl, context)
75
JSSVGPathSegLinetoHorizontalAbs::JSSVGPathSegLinetoHorizontalAbs(NonNullPassRefPtr<Structure> structure, JSDOMGlobalObject* globalObject, PassRefPtr<SVGPathSegLinetoHorizontalAbs> impl, SVGElement* context)
76
: JSSVGPathSeg(structure, globalObject, impl, context)
91
87
return getStaticValueSlot<JSSVGPathSegLinetoHorizontalAbs, Base>(exec, &JSSVGPathSegLinetoHorizontalAbsTable, this, propertyName, slot);
94
JSValuePtr jsSVGPathSegLinetoHorizontalAbsX(ExecState* exec, const Identifier&, const PropertySlot& slot)
96
SVGPathSegLinetoHorizontalAbs* imp = static_cast<SVGPathSegLinetoHorizontalAbs*>(static_cast<JSSVGPathSegLinetoHorizontalAbs*>(asObject(slot.slotBase()))->impl());
90
bool JSSVGPathSegLinetoHorizontalAbs::getOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor)
92
return getStaticValueDescriptor<JSSVGPathSegLinetoHorizontalAbs, Base>(exec, &JSSVGPathSegLinetoHorizontalAbsTable, this, propertyName, descriptor);
95
JSValue jsSVGPathSegLinetoHorizontalAbsX(ExecState* exec, const Identifier&, const PropertySlot& slot)
97
JSSVGPathSegLinetoHorizontalAbs* castedThis = static_cast<JSSVGPathSegLinetoHorizontalAbs*>(asObject(slot.slotBase()));
99
SVGPathSegLinetoHorizontalAbs* imp = static_cast<SVGPathSegLinetoHorizontalAbs*>(castedThis->impl());
97
100
return jsNumber(exec, imp->x());
100
void JSSVGPathSegLinetoHorizontalAbs::put(ExecState* exec, const Identifier& propertyName, JSValuePtr value, PutPropertySlot& slot)
103
void JSSVGPathSegLinetoHorizontalAbs::put(ExecState* exec, const Identifier& propertyName, JSValue value, PutPropertySlot& slot)
102
105
lookupPut<JSSVGPathSegLinetoHorizontalAbs, Base>(exec, propertyName, value, &JSSVGPathSegLinetoHorizontalAbsTable, this, slot);
105
void setJSSVGPathSegLinetoHorizontalAbsX(ExecState* exec, JSObject* thisObject, JSValuePtr value)
108
void setJSSVGPathSegLinetoHorizontalAbsX(ExecState* exec, JSObject* thisObject, JSValue value)
107
110
SVGPathSegLinetoHorizontalAbs* imp = static_cast<SVGPathSegLinetoHorizontalAbs*>(static_cast<JSSVGPathSegLinetoHorizontalAbs*>(thisObject)->impl());
108
imp->setX(value->toFloat(exec));
111
imp->setX(value.toFloat(exec));
109
112
if (static_cast<JSSVGPathSegLinetoHorizontalAbs*>(thisObject)->context())
110
113
static_cast<JSSVGPathSegLinetoHorizontalAbs*>(thisObject)->context()->svgAttributeChanged(static_cast<JSSVGPathSegLinetoHorizontalAbs*>(thisObject)->impl()->associatedAttributeName());