From 1c217aae2d952c246951e6254d71b68d8ca3f061 Mon Sep 17 00:00:00 2001 From: David Zbarsky Date: Tue, 23 Jul 2013 01:34:17 -0700 Subject: [PATCH] Bug 888685: SVGAnimatedRect shouldn't inherit nsISupports r=Ms2ger --- content/svg/content/src/SVGAnimatedRect.cpp | 9 ++------- content/svg/content/src/SVGAnimatedRect.h | 7 +++---- dom/bindings/Bindings.conf | 4 ++++ 3 files changed, 9 insertions(+), 11 deletions(-) diff --git a/content/svg/content/src/SVGAnimatedRect.cpp b/content/svg/content/src/SVGAnimatedRect.cpp index dd8cde690d0e..caa5c13db43b 100644 --- a/content/svg/content/src/SVGAnimatedRect.cpp +++ b/content/svg/content/src/SVGAnimatedRect.cpp @@ -12,15 +12,10 @@ namespace mozilla { namespace dom { -NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(SVGAnimatedRect) - NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY - NS_INTERFACE_MAP_ENTRY(nsISupports) -NS_INTERFACE_MAP_END - NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(SVGAnimatedRect, mSVGElement) -NS_IMPL_CYCLE_COLLECTING_ADDREF(SVGAnimatedRect) -NS_IMPL_CYCLE_COLLECTING_RELEASE(SVGAnimatedRect) +NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(SVGAnimatedRect, AddRef) +NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(SVGAnimatedRect, Release) SVGAnimatedRect::SVGAnimatedRect(nsSVGViewBox* aVal, nsSVGElement* aSVGElement) : mVal(aVal) diff --git a/content/svg/content/src/SVGAnimatedRect.h b/content/svg/content/src/SVGAnimatedRect.h index 9e720fcedd58..6d0f977f9a71 100644 --- a/content/svg/content/src/SVGAnimatedRect.h +++ b/content/svg/content/src/SVGAnimatedRect.h @@ -18,12 +18,11 @@ class nsSVGViewBox; namespace mozilla { namespace dom { -class SVGAnimatedRect MOZ_FINAL : public nsISupports, - public nsWrapperCache +class SVGAnimatedRect MOZ_FINAL : public nsWrapperCache { public: - NS_DECL_CYCLE_COLLECTING_ISUPPORTS - NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(SVGAnimatedRect) + NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(SVGAnimatedRect) + NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(SVGAnimatedRect) SVGAnimatedRect(nsSVGViewBox* aVal, nsSVGElement* aSVGElement); diff --git a/dom/bindings/Bindings.conf b/dom/bindings/Bindings.conf index 68e7fb18953e..8a719341caf2 100644 --- a/dom/bindings/Bindings.conf +++ b/dom/bindings/Bindings.conf @@ -888,6 +888,10 @@ DOMInterfaces = { 'headerFile': 'SVGAnimatedPreserveAspectRatio.h' }, +'SVGAnimatedRect' : { + 'nativeOwnership': 'refcounted' +}, + 'SVGAnimatedTransformList': { 'nativeOwnership': 'refcounted', },