Bug 888685: SVGAngle shouldn't inherit nsISupports r=Ms2ger

This commit is contained in:
David Zbarsky 2013-07-05 11:57:35 -07:00
parent fc21e4ca71
commit 3643890665
3 changed files with 12 additions and 26 deletions

View File

@ -13,14 +13,8 @@ using namespace mozilla::dom;
NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(SVGAngle, mSVGElement)
NS_IMPL_CYCLE_COLLECTING_ADDREF(SVGAngle)
NS_IMPL_CYCLE_COLLECTING_RELEASE(SVGAngle)
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(SVGAngle)
NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
NS_INTERFACE_MAP_ENTRY(SVGAngle)
NS_INTERFACE_MAP_ENTRY(nsISupports)
NS_INTERFACE_MAP_END
NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(SVGAngle, AddRef)
NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(SVGAngle, Release)
JSObject*
SVGAngle::WrapObject(JSContext* aCx, JS::Handle<JSObject*> aScope)

View File

@ -3,7 +3,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#pragma once
#ifndef mozilla_dom_SVGAngle_h
#define mozilla_dom_SVGAngle_h
#include "nsWrapperCache.h"
#include "nsSVGElement.h"
@ -11,21 +12,10 @@
class nsSVGAngle;
// We make SVGAngle a pseudo-interface to allow us to QI to it in order
// to check that the objects that scripts pass in are our our *native*
// transform objects.
// {da9670f6-6d3d-4fb3-974c-9d6bad8dcd53}
#define MOZILLA_SVGANGLE_IID \
{0x2cd27ef5, 0x81d8, 0x4720, \
{0x81, 0x42, 0x66, 0xc6, 0xa9, 0xbe, 0xc3, 0xeb } }
namespace mozilla {
namespace dom {
class SVGAngle MOZ_FINAL : public nsISupports,
public nsWrapperCache
class SVGAngle MOZ_FINAL : public nsWrapperCache
{
public:
typedef enum {
@ -34,9 +24,8 @@ public:
CreatedValue
} AngleType;
NS_DECLARE_STATIC_IID_ACCESSOR(MOZILLA_SVGANGLE_IID)
NS_DECL_CYCLE_COLLECTING_ISUPPORTS
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(SVGAngle)
NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(SVGAngle)
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(SVGAngle)
SVGAngle(nsSVGAngle* aVal, nsSVGElement *aSVGElement, AngleType aType)
: mVal(aVal), mSVGElement(aSVGElement), mType(aType)
@ -66,8 +55,7 @@ protected:
AngleType mType;
};
NS_DEFINE_STATIC_IID_ACCESSOR(SVGAngle, MOZILLA_SVGANGLE_IID)
} //namespace dom
} //namespace mozilla
#endif // mozilla_dom_SVGAngle_h

View File

@ -824,6 +824,10 @@ DOMInterfaces = {
'nativeType': 'nsCSSStyleSheet',
},
'SVGAngle' : {
'nativeOwnership': 'refcounted'
},
'SVGAnimatedBoolean' : {
'nativeOwnership': 'refcounted'
},