diff --git a/dom/src/base/nsDOMClassInfo.cpp b/dom/src/base/nsDOMClassInfo.cpp index 918e10f93e8e..5158d3623baa 100644 --- a/dom/src/base/nsDOMClassInfo.cpp +++ b/dom/src/base/nsDOMClassInfo.cpp @@ -3214,11 +3214,9 @@ nsWindowSH::AddProperty(nsIXPConnectWrappedNative *wrapper, JSContext *cx, // exception, we must make sure that exception is propagated. *_retval = PR_FALSE; - - return NS_OK; } - return nsEventReceiverSH::AddProperty(wrapper, cx, obj, id, vp, _retval); + return NS_OK; } NS_IMETHODIMP @@ -4617,9 +4615,7 @@ nsEventReceiverSH::NewResolve(nsIXPConnectWrappedNative *wrapper, JSContext *cx, JSObject *obj, jsval id, PRUint32 flags, JSObject **objp, PRBool *_retval) { - // If we're assigning to an on* property, we'll register the handler - // in our ::SetProperty() hook, so no need to do it here too. - if (!JSVAL_IS_STRING(id) || (flags & JSRESOLVE_ASSIGNING)) { + if (!JSVAL_IS_STRING(id)) { return NS_OK; } @@ -4651,14 +4647,6 @@ nsEventReceiverSH::SetProperty(nsIXPConnectWrappedNative *wrapper, return RegisterCompileHandler(wrapper, cx, obj, id, PR_FALSE, &did_compile); } -NS_IMETHODIMP -nsEventReceiverSH::AddProperty(nsIXPConnectWrappedNative *wrapper, - JSContext *cx, JSObject *obj, jsval id, - jsval *vp, PRBool *_retval) -{ - return nsEventReceiverSH::SetProperty(wrapper, cx, obj, id, vp, _retval); -} - /* NS_IMETHODIMP nsEventReceiverSH::OnFinalize(...) @@ -5304,7 +5292,7 @@ nsHTMLDocumentSH::DocumentOpen(JSContext *cx, JSObject *obj, uintN argc, nsresult rv = sXPConnect->GetWrappedNativeOfJSObject(cx, obj, getter_AddRefs(wrapper)); if (NS_FAILED(rv)) { - nsDOMClassInfo::ThrowJSException(cx, rv); + ThrowJSException(cx, rv); return JS_FALSE; } diff --git a/dom/src/base/nsDOMClassInfo.h b/dom/src/base/nsDOMClassInfo.h index 1bf4022c5b3f..9aadf7b51a20 100644 --- a/dom/src/base/nsDOMClassInfo.h +++ b/dom/src/base/nsDOMClassInfo.h @@ -310,8 +310,6 @@ public: NS_IMETHOD SetProperty(nsIXPConnectWrappedNative *wrapper, JSContext *cx, JSObject *obj, jsval id, jsval *vp, PRBool *_retval); - NS_IMETHOD AddProperty(nsIXPConnectWrappedNative *wrapper, JSContext *cx, - JSObject *obj, jsval id, jsval *vp, PRBool *_retval); };