diff options
Diffstat (limited to 'WebCore/bindings/js/JSWebGLFloatArrayCustom.cpp')
-rw-r--r-- | WebCore/bindings/js/JSWebGLFloatArrayCustom.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/WebCore/bindings/js/JSWebGLFloatArrayCustom.cpp b/WebCore/bindings/js/JSWebGLFloatArrayCustom.cpp index 5f5b24f..f4acbcf 100644 --- a/WebCore/bindings/js/JSWebGLFloatArrayCustom.cpp +++ b/WebCore/bindings/js/JSWebGLFloatArrayCustom.cpp @@ -38,7 +38,7 @@ namespace WebCore { void JSWebGLFloatArray::indexSetter(JSC::ExecState* exec, unsigned index, JSC::JSValue value) { - impl()->set(index, static_cast<float>(value.toInt32(exec))); + impl()->set(index, static_cast<float>(value.toNumber(exec))); } JSC::JSValue toJS(JSC::ExecState* exec, JSDOMGlobalObject* globalObject, WebGLFloatArray* object) @@ -52,9 +52,9 @@ JSC::JSValue JSWebGLFloatArray::set(JSC::ExecState* exec, JSC::ArgList const& ar return throwError(exec, SyntaxError); if (args.size() == 2 && args.at(0).isInt32()) { - // void set(in unsigned long index, in long value); + // void set(in unsigned long index, in float value); unsigned index = args.at(0).toUInt32(exec); - impl()->set(index, static_cast<signed char>(args.at(1).toInt32(exec))); + impl()->set(index, static_cast<float>(args.at(1).toNumber(exec))); return jsUndefined(); } |