bool runtimeObjectCustomPut(ExecState* exec, const Identifier& propertyName, JSValue value, HTMLElement* element, PutPropertySlot& slot) { RuntimeObjectImp* runtimeObject = getRuntimeObject(exec, element); if (!runtimeObject) return 0; if (!runtimeObject->hasProperty(exec, propertyName)) return false; runtimeObject->put(exec, propertyName, value, slot); return true; }
bool runtimeObjectCustomGetOwnPropertySlot(ExecState* exec, const Identifier& propertyName, PropertySlot& slot, JSHTMLElement* element) { RuntimeObjectImp* runtimeObject = getRuntimeObject(exec, element->impl()); if (!runtimeObject) return false; if (!runtimeObject->hasProperty(exec, propertyName)) return false; slot.setCustom(element, runtimeObjectPropertyGetter); return true; }
bool runtimeObjectCustomGetOwnPropertyDescriptor(ExecState* exec, const Identifier& propertyName, PropertyDescriptor& descriptor, JSHTMLElement* element) { RuntimeObjectImp* runtimeObject = getRuntimeObject(exec, element->impl()); if (!runtimeObject) return false; if (!runtimeObject->hasProperty(exec, propertyName)) return false; PropertySlot slot; slot.setCustom(element, runtimeObjectPropertyGetter); // While we don't know what the plugin allows, we do know that we prevent // enumeration or deletion of properties, so we mark plugin properties // as DontEnum | DontDelete descriptor.setDescriptor(slot.getValue(exec, propertyName), DontEnum | DontDelete); return true; }