コード例 #1
0
JSValue jsSVGSymbolElementViewBox(ExecState* exec, const Identifier&, const PropertySlot& slot)
{
    UNUSED_PARAM(exec);
    SVGSymbolElement* imp = static_cast<SVGSymbolElement*>(static_cast<JSSVGSymbolElement*>(asObject(slot.slotBase()))->impl());
    RefPtr<SVGAnimatedRect> obj = imp->viewBoxAnimated();
    return toJS(exec, obj.get(), imp);
}
コード例 #2
0
static v8::Handle<v8::Value> viewBoxAttrGetter(v8::Local<v8::String> name, const v8::AccessorInfo& info)
{
    INC_STATS("DOM.SVGSymbolElement.viewBox._get");
    SVGSymbolElement* imp = V8SVGSymbolElement::toNative(info.Holder());
    SVGElement* context = imp;
    PassRefPtr<SVGAnimatedRect> resultAsPassRefPtr = V8Proxy::withSVGContext(imp->viewBoxAnimated(), context);
    return toV8(resultAsPassRefPtr);
}