Merge mozilla-inbound to mozilla-central. a=merge
authorDaniel Varga <dvarga@mozilla.com>
Tue, 19 Mar 2019 11:50:28 +0200
changeset 464921 8803315158232628b5a63ad1e2dc84b28da805eb
parent 464915 70baa37ae1eb12e2dec584fecf82453d6f4b17b4 (current diff)
parent 464920 7a76a71448ff98dd6705f38dda0ad06a6da9e032 (diff)
child 464970 6ff93d4a7e1c895fd88f82af752a5c258ceac49d
child 465067 62a7f082c4434a943649132f0ef344f5f120a444
push id35728
push userdvarga@mozilla.com
push dateTue, 19 Mar 2019 09:50:54 +0000
treeherdermozilla-central@880331515823 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmerge
milestone68.0a1
first release with
nightly linux32
880331515823 / 68.0a1 / 20190319095054 / files
nightly linux64
880331515823 / 68.0a1 / 20190319095054 / files
nightly mac
880331515823 / 68.0a1 / 20190319095054 / files
nightly win32
880331515823 / 68.0a1 / 20190319095054 / files
nightly win64
880331515823 / 68.0a1 / 20190319095054 / files
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
releases
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Merge mozilla-inbound to mozilla-central. a=merge
dom/svg/SVGAnimatedAngle.cpp
dom/svg/SVGAnimatedAngle.h
dom/svg/SVGAnimatedBoolean.cpp
dom/svg/SVGAnimatedBoolean.h
dom/svg/SVGAnimatedEnumeration.cpp
dom/svg/SVGAnimatedEnumeration.h
dom/svg/SVGAnimatedInteger.cpp
dom/svg/SVGAnimatedInteger.h
dom/svg/SVGAnimatedLength.cpp
dom/svg/SVGAnimatedLength.h
dom/svg/SVGAnimatedNumber.cpp
dom/svg/SVGAnimatedNumber.h
dom/svg/SVGAnimatedString.cpp
dom/svg/SVGAnimatedString.h
--- a/build/mozconfig.comm-support
+++ b/build/mozconfig.comm-support
@@ -22,17 +22,17 @@
 if [ "$(dirname "$2")" = "$topsrcdir" ]; then
   # No weirdness
   if [ -d "$topsrcdir/mail" ]; then
     # Building with comm-central as top-level directory.
     echo "ERROR: Should not include mozilla/build/mozconfig.comm when building"
     echo "       with comm-central as top-level directory."
     exit 1
   elif [ -d "$topsrcdir/comm/mail" ]; then
-    # Building with mozila-central as top-level directory.
+    # Building with mozilla-central as top-level directory.
     . "$topsrcdir/comm/build/mozconfig.comm-support"
   else
     echo "ERROR: Unknown build directory layout."
     exit 1
   fi
 elif [ "$(dirname "$2")" = "$(dirname "$topsrcdir")" ]; then
   if [ -d "$topsrcdir/../mail" ]; then
     # Building with comm-central as top-level directory;
--- a/dom/bindings/Bindings.conf
+++ b/dom/bindings/Bindings.conf
@@ -761,36 +761,71 @@ DOMInterfaces = {
     'wrapperCache': False,
 },
 
 'StyleSheet': {
     'nativeType': 'mozilla::StyleSheet',
     'headerFile': 'mozilla/StyleSheetInlines.h',
 },
 
+'SVGAnimatedAngle': {
+    'nativeType': 'mozilla::dom::DOMSVGAnimatedAngle',
+    'headerFile': 'DOMSVGAnimatedAngle.h',
+},
+
+'SVGAnimatedBoolean': {
+    'nativeType': 'mozilla::dom::DOMSVGAnimatedBoolean',
+    'headerFile': 'DOMSVGAnimatedBoolean.h',
+},
+
+'SVGAnimatedEnumeration': {
+    'nativeType': 'mozilla::dom::DOMSVGAnimatedEnumeration',
+    'headerFile': 'DOMSVGAnimatedEnumeration.h',
+},
+
+'SVGAnimatedInteger': {
+    'nativeType': 'mozilla::dom::DOMSVGAnimatedInteger',
+    'headerFile': 'DOMSVGAnimatedInteger.h',
+},
+
+'SVGAnimatedPreserveAspectRatio': {
+    'nativeType': 'mozilla::dom::DOMSVGAnimatedPreserveAspectRatio',
+    'headerFile': 'SVGAnimatedPreserveAspectRatio.h'
+},
+
+'SVGAnimatedLength': {
+    'nativeType': 'mozilla::dom::DOMSVGAnimatedLength',
+    'headerFile': 'DOMSVGAnimatedLength.h',
+},
+
 'SVGAnimatedLengthList': {
     'nativeType': 'mozilla::dom::DOMSVGAnimatedLengthList',
     'headerFile': 'DOMSVGAnimatedLengthList.h',
 },
 
+'SVGAnimatedNumber': {
+    'nativeType': 'mozilla::dom::DOMSVGAnimatedNumber',
+    'headerFile': 'DOMSVGAnimatedNumber.h',
+},
+
 'SVGAnimatedNumberList': {
     'nativeType': 'mozilla::dom::DOMSVGAnimatedNumberList',
     'headerFile': 'DOMSVGAnimatedNumberList.h'
 },
 
+'SVGAnimatedString': {
+    'nativeType': 'mozilla::dom::DOMSVGAnimatedString',
+    'headerFile': 'DOMSVGAnimatedString.h',
+},
+
 'SVGAnimatedTransformList': {
     'nativeType': 'mozilla::dom::DOMSVGAnimatedTransformList',
     'headerFile': 'DOMSVGAnimatedTransformList.h'
 },
 
-'SVGAnimatedPreserveAspectRatio': {
-    'nativeType': 'mozilla::dom::DOMSVGAnimatedPreserveAspectRatio',
-    'headerFile': 'SVGAnimatedPreserveAspectRatio.h'
-},
-
 'SVGAngle': {
     'nativeType': 'mozilla::dom::DOMSVGAngle',
     'headerFile': 'DOMSVGAngle.h'
 },
 
 'SVGAnimationElement': {
     'concrete': False
 },
@@ -971,16 +1006,21 @@ DOMInterfaces = {
 'SVGRadialGradientElement': {
     'headerFile': 'mozilla/dom/SVGGradientElement.h',
 },
 
 'SVGRect': {
     'nativeType': 'mozilla::dom::SVGIRect'
 },
 
+'SVGStringList': {
+    'nativeType': 'mozilla::DOMSVGStringList',
+    'headerFile': 'DOMSVGStringList.h',
+},
+
 'SVGTextContentElement': {
     'concrete': False
 },
 
 'SVGTextPositioningElement': {
     'concrete': False
 },
 
@@ -992,21 +1032,16 @@ DOMInterfaces = {
     }
 },
 
 'SVGTransformList': {
     'nativeType': 'mozilla::DOMSVGTransformList',
     'headerFile': 'DOMSVGTransformList.h'
 },
 
-'SVGStringList': {
-    'nativeType': 'mozilla::DOMSVGStringList',
-    'headerFile': 'DOMSVGStringList.h',
-},
-
 'SVGUnitTypes' : {
     'concrete': False,
 },
 
 'SVGZoomAndPan' : {
     'concrete': False,
 },
 
--- a/dom/canvas/TexUnpackBlob.cpp
+++ b/dom/canvas/TexUnpackBlob.cpp
@@ -354,17 +354,17 @@ bool TexUnpackBlob::ConvertIfNeeded(
   ////
 
   const auto dstTotalBytes = CheckedUint32(rowCount) * dstStride;
   if (!dstTotalBytes.isValid()) {
     webgl->ErrorOutOfMemory("Calculation failed.");
     return false;
   }
 
-  UniqueBuffer dstBuffer = calloc(1, dstTotalBytes.value());
+  UniqueBuffer dstBuffer = calloc(1u, (size_t)dstTotalBytes.value());
   if (!dstBuffer.get()) {
     webgl->ErrorOutOfMemory("Failed to allocate dest buffer.");
     return false;
   }
   const auto dstBegin = static_cast<uint8_t*>(dstBuffer.get());
 
   ////
 
--- a/dom/canvas/WebGLContextBuffers.cpp
+++ b/dom/canvas/WebGLContextBuffers.cpp
@@ -298,20 +298,23 @@ void WebGLContext::BufferDataImpl(GLenum
 void WebGLContext::BufferData(GLenum target, WebGLsizeiptr size, GLenum usage) {
   const FuncScope funcScope(*this, "bufferData");
   if (IsContextLost()) return;
 
   if (!ValidateNonNegative("size", size)) return;
 
   ////
 
-  const UniqueBuffer zeroBuffer(calloc(size, 1));
+  const auto checkedSize = CheckedInt<size_t>(size);
+  if (!checkedSize.isValid()) return ErrorOutOfMemory("size too large for platform.");
+
+  const UniqueBuffer zeroBuffer(calloc(checkedSize.value(), 1u));
   if (!zeroBuffer) return ErrorOutOfMemory("Failed to allocate zeros.");
 
-  BufferDataImpl(target, size_t(size), (const uint8_t*)zeroBuffer.get(), usage);
+  BufferDataImpl(target, checkedSize.value(), (const uint8_t*)zeroBuffer.get(), usage);
 }
 
 void WebGLContext::BufferData(GLenum target,
                               const dom::Nullable<dom::ArrayBuffer>& maybeSrc,
                               GLenum usage) {
   const FuncScope funcScope(*this, "bufferData");
   if (IsContextLost()) return;
 
--- a/dom/canvas/WebGLTexture.cpp
+++ b/dom/canvas/WebGLTexture.cpp
@@ -581,17 +581,17 @@ static bool ZeroTextureData(const WebGLC
     checkedByteCount *= widthBlocks;
     checkedByteCount *= heightBlocks;
     checkedByteCount *= depth;
 
     if (!checkedByteCount.isValid()) return false;
 
     const size_t byteCount = checkedByteCount.value();
 
-    UniqueBuffer zeros = calloc(1, byteCount);
+    UniqueBuffer zeros = calloc(1u, byteCount);
     if (!zeros) return false;
 
     ScopedUnpackReset scopedReset(webgl);
     gl->fPixelStorei(LOCAL_GL_UNPACK_ALIGNMENT, 1);  // Don't bother with
                                                      // striding it well.
 
     const auto error =
         DoCompressedTexSubImage(gl, target.get(), level, 0, 0, 0, width, height,
@@ -618,17 +618,17 @@ static bool ZeroTextureData(const WebGLC
   checkedByteCount *= width;
   checkedByteCount *= height;
   checkedByteCount *= depth;
 
   if (!checkedByteCount.isValid()) return false;
 
   const size_t byteCount = checkedByteCount.value();
 
-  UniqueBuffer zeros = calloc(1, byteCount);
+  UniqueBuffer zeros = calloc(1u, byteCount);
   if (!zeros) return false;
 
   ScopedUnpackReset scopedReset(webgl);
   gl->fPixelStorei(LOCAL_GL_UNPACK_ALIGNMENT,
                    1);  // Don't bother with striding it well.
   const auto error = DoTexSubImage(gl, target, level, 0, 0, 0, width, height,
                                    depth, packing, zeros.get());
   return !error;
--- a/dom/canvas/WebGLTextureUpload.cpp
+++ b/dom/canvas/WebGLTextureUpload.cpp
@@ -1946,22 +1946,22 @@ static bool DoCopyTexOrSubImage(WebGLCon
   nsCString errorText;
   do {
     const auto& idealUnpack = dstUsage->idealUnpack;
     if (!isSubImage) {
       UniqueBuffer buffer;
 
       if (uint32_t(rwWidth) != dstWidth || uint32_t(rwHeight) != dstHeight) {
         const auto& pi = idealUnpack->ToPacking();
-        CheckedUint32 byteCount = BytesPerPixel(pi);
+        CheckedInt<size_t> byteCount = BytesPerPixel(pi);
         byteCount *= dstWidth;
         byteCount *= dstHeight;
 
         if (byteCount.isValid()) {
-          buffer = calloc(1, byteCount.value());
+          buffer = calloc(1u, byteCount.value());
         }
 
         if (!buffer.get()) {
           webgl->ErrorOutOfMemory("Ran out of memory allocating zeros.");
           return false;
         }
       }
 
--- a/dom/canvas/WebGLTypes.h
+++ b/dom/canvas/WebGLTypes.h
@@ -1,30 +1,62 @@
 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef WEBGLTYPES_H_
 #define WEBGLTYPES_H_
 
+#include <limits>
+
 // Most WebIDL typedefs are identical to their OpenGL counterparts.
 #include "GLTypes.h"
 
 // Manual reflection of WebIDL typedefs that are different from their
 // OpenGL counterparts.
 typedef int64_t WebGLsizeiptr;
 typedef int64_t WebGLintptr;
 typedef bool WebGLboolean;
 
+// -
+
 namespace mozilla {
 namespace gl {
 class GLContext;  // This is going to be needed a lot.
 }  // namespace gl
 
+// -
+// Prevent implicit conversions into calloc and malloc. (mozilla namespace only!)
+
+template<typename DestT>
+class ForbidNarrowing final
+{
+  DestT mVal;
+
+public:
+  template<typename SrcT>
+  MOZ_IMPLICIT ForbidNarrowing(SrcT val) : mVal(val) {
+    static_assert(std::numeric_limits<SrcT>::min() >= std::numeric_limits<DestT>::min(),
+                  "SrcT must be narrower than DestT.");
+    static_assert(std::numeric_limits<SrcT>::max() <= std::numeric_limits<DestT>::max(),
+                  "SrcT must be narrower than DestT.");
+  }
+
+  explicit operator DestT() const { return mVal; }
+};
+
+inline void* malloc(const ForbidNarrowing<size_t> s) {
+  return ::malloc(size_t(s));
+}
+
+inline void* calloc(const ForbidNarrowing<size_t> n, const ForbidNarrowing<size_t> size) {
+  return ::calloc(size_t(n), size_t(size));
+}
+
 /*
  * Implementing WebGL (or OpenGL ES 2.0) on top of desktop OpenGL requires
  * emulating the vertex attrib 0 array when it's not enabled. Indeed,
  * OpenGL ES 2.0 allows drawing without vertex attrib 0 array enabled, but
  * desktop OpenGL does not allow that.
  */
 enum class WebGLVertexAttrib0Status : uint8_t {
   Default,                     // default status - no emulation needed
rename from dom/svg/SVGAnimatedAngle.cpp
rename to dom/svg/DOMSVGAnimatedAngle.cpp
--- a/dom/svg/SVGAnimatedAngle.cpp
+++ b/dom/svg/DOMSVGAnimatedAngle.cpp
@@ -1,30 +1,31 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#include "SVGAnimatedAngle.h"
+#include "DOMSVGAnimatedAngle.h"
+
 #include "SVGOrient.h"
 #include "mozilla/dom/SVGAnimatedAngleBinding.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
 
-NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(SVGAnimatedAngle, mSVGElement)
+NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(DOMSVGAnimatedAngle, mSVGElement)
 
-NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(SVGAnimatedAngle, AddRef)
-NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(SVGAnimatedAngle, Release)
+NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(DOMSVGAnimatedAngle, AddRef)
+NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(DOMSVGAnimatedAngle, Release)
 
-JSObject* SVGAnimatedAngle::WrapObject(JSContext* aCx,
-                                       JS::Handle<JSObject*> aGivenProto) {
+JSObject* DOMSVGAnimatedAngle::WrapObject(JSContext* aCx,
+                                          JS::Handle<JSObject*> aGivenProto) {
   return SVGAnimatedAngle_Binding::Wrap(aCx, this, aGivenProto);
 }
 
-already_AddRefed<DOMSVGAngle> SVGAnimatedAngle::BaseVal() {
+already_AddRefed<DOMSVGAngle> DOMSVGAnimatedAngle::BaseVal() {
   return mVal->ToDOMBaseVal(mSVGElement);
 }
 
-already_AddRefed<DOMSVGAngle> SVGAnimatedAngle::AnimVal() {
+already_AddRefed<DOMSVGAngle> DOMSVGAnimatedAngle::AnimVal() {
   return mVal->ToDOMAnimVal(mSVGElement);
 }
rename from dom/svg/SVGAnimatedAngle.h
rename to dom/svg/DOMSVGAnimatedAngle.h
--- a/dom/svg/SVGAnimatedAngle.h
+++ b/dom/svg/DOMSVGAnimatedAngle.h
@@ -1,47 +1,47 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#ifndef mozilla_dom_SVGAnimatedAngle_h
-#define mozilla_dom_SVGAnimatedAngle_h
+#ifndef mozilla_dom_DOMSVGAnimatedAngle_h
+#define mozilla_dom_DOMSVGAnimatedAngle_h
 
 #include "nsWrapperCache.h"
 #include "SVGElement.h"
 #include "mozilla/Attributes.h"
 
 namespace mozilla {
 
 class SVGOrient;
 
 namespace dom {
 
 class DOMSVGAngle;
 
-class SVGAnimatedAngle final : public nsWrapperCache {
+class DOMSVGAnimatedAngle final : public nsWrapperCache {
  public:
-  NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(SVGAnimatedAngle)
-  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(SVGAnimatedAngle)
+  NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(DOMSVGAnimatedAngle)
+  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(DOMSVGAnimatedAngle)
 
-  SVGAnimatedAngle(SVGOrient* aVal, SVGElement* aSVGElement)
+  DOMSVGAnimatedAngle(SVGOrient* aVal, SVGElement* aSVGElement)
       : mVal(aVal), mSVGElement(aSVGElement) {}
 
   // WebIDL
   SVGElement* GetParentObject() { return mSVGElement; }
   virtual JSObject* WrapObject(JSContext* aCx,
                                JS::Handle<JSObject*> aGivenProto) override;
   already_AddRefed<DOMSVGAngle> BaseVal();
   already_AddRefed<DOMSVGAngle> AnimVal();
 
  protected:
-  ~SVGAnimatedAngle();
+  ~DOMSVGAnimatedAngle();
 
   SVGOrient* mVal;  // kept alive because it belongs to content
   RefPtr<SVGElement> mSVGElement;
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
-#endif  // mozilla_dom_SVGAnimatedAngle_h
+#endif  // mozilla_dom_DOMSVGAnimatedAngle_h
rename from dom/svg/SVGAnimatedBoolean.cpp
rename to dom/svg/DOMSVGAnimatedBoolean.cpp
--- a/dom/svg/SVGAnimatedBoolean.cpp
+++ b/dom/svg/DOMSVGAnimatedBoolean.cpp
@@ -1,21 +1,23 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#include "SVGAnimatedBoolean.h"
+#include "DOMSVGAnimatedBoolean.h"
+
 #include "mozilla/dom/SVGAnimatedBooleanBinding.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
 
-NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(SVGAnimatedBoolean, mSVGElement)
+NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(DOMSVGAnimatedBoolean,
+                                               mSVGElement)
 
-NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(SVGAnimatedBoolean, AddRef)
-NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(SVGAnimatedBoolean, Release)
+NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(DOMSVGAnimatedBoolean, AddRef)
+NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(DOMSVGAnimatedBoolean, Release)
 
-JSObject* SVGAnimatedBoolean::WrapObject(JSContext* aCx,
-                                         JS::Handle<JSObject*> aGivenProto) {
+JSObject* DOMSVGAnimatedBoolean::WrapObject(JSContext* aCx,
+                                            JS::Handle<JSObject*> aGivenProto) {
   return SVGAnimatedBoolean_Binding::Wrap(aCx, this, aGivenProto);
 }
rename from dom/svg/SVGAnimatedBoolean.h
rename to dom/svg/DOMSVGAnimatedBoolean.h
--- a/dom/svg/SVGAnimatedBoolean.h
+++ b/dom/svg/DOMSVGAnimatedBoolean.h
@@ -1,46 +1,46 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#ifndef mozilla_dom_SVGAnimatedBoolean_h
-#define mozilla_dom_SVGAnimatedBoolean_h
+#ifndef mozilla_dom_DOMSVGAnimatedBoolean_h
+#define mozilla_dom_DOMSVGAnimatedBoolean_h
 
 #include "SVGBoolean.h"
 #include "nsWrapperCache.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/dom/SVGElement.h"
 
 namespace mozilla {
 namespace dom {
 
-class SVGAnimatedBoolean final : public nsWrapperCache {
-  NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(SVGAnimatedBoolean)
-  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(SVGAnimatedBoolean)
+class DOMSVGAnimatedBoolean final : public nsWrapperCache {
+  NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(DOMSVGAnimatedBoolean)
+  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(DOMSVGAnimatedBoolean)
 
-  SVGAnimatedBoolean(SVGBoolean* aVal, SVGElement* aSVGElement)
+  DOMSVGAnimatedBoolean(SVGBoolean* aVal, SVGElement* aSVGElement)
       : mVal(aVal), mSVGElement(aSVGElement) {}
 
   // WebIDL
   SVGElement* GetParentObject() const { return mSVGElement; }
   virtual JSObject* WrapObject(JSContext* aCx,
                                JS::Handle<JSObject*> aGivenProto) override;
   bool BaseVal() const { return mVal->GetBaseValue(); }
   void SetBaseVal(bool aValue) { mVal->SetBaseValue(aValue, mSVGElement); }
   bool AnimVal() const {
     mSVGElement->FlushAnimations();
     return mVal->GetAnimValue();
   }
 
  protected:
-  ~SVGAnimatedBoolean();
+  ~DOMSVGAnimatedBoolean();
 
   SVGBoolean* mVal;  // kept alive because it belongs to content
   RefPtr<SVGElement> mSVGElement;
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
-#endif  // mozilla_dom_SVGAnimatedBoolean_h
+#endif  // mozilla_dom_DOMSVGAnimatedBoolean_h
rename from dom/svg/SVGAnimatedEnumeration.cpp
rename to dom/svg/DOMSVGAnimatedEnumeration.cpp
--- a/dom/svg/SVGAnimatedEnumeration.cpp
+++ b/dom/svg/DOMSVGAnimatedEnumeration.cpp
@@ -1,31 +1,31 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#include "mozilla/dom/SVGAnimatedEnumeration.h"
+#include "DOMSVGAnimatedEnumeration.h"
 
 #include "mozilla/dom/SVGAnimatedEnumerationBinding.h"
 
 namespace mozilla {
 namespace dom {
 
-NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(SVGAnimatedEnumeration,
+NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(DOMSVGAnimatedEnumeration,
                                                mSVGElement)
 
-NS_IMPL_CYCLE_COLLECTING_ADDREF(SVGAnimatedEnumeration)
-NS_IMPL_CYCLE_COLLECTING_RELEASE(SVGAnimatedEnumeration)
+NS_IMPL_CYCLE_COLLECTING_ADDREF(DOMSVGAnimatedEnumeration)
+NS_IMPL_CYCLE_COLLECTING_RELEASE(DOMSVGAnimatedEnumeration)
 
-NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(SVGAnimatedEnumeration)
+NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(DOMSVGAnimatedEnumeration)
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
   NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
-JSObject* SVGAnimatedEnumeration::WrapObject(
+JSObject* DOMSVGAnimatedEnumeration::WrapObject(
     JSContext* aCx, JS::Handle<JSObject*> aGivenProto) {
   return SVGAnimatedEnumeration_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 }  // namespace dom
 }  // namespace mozilla
rename from dom/svg/SVGAnimatedEnumeration.h
rename to dom/svg/DOMSVGAnimatedEnumeration.h
--- a/dom/svg/SVGAnimatedEnumeration.h
+++ b/dom/svg/DOMSVGAnimatedEnumeration.h
@@ -1,41 +1,41 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#ifndef mozilla_dom_SVGAnimatedEnumeration_h
-#define mozilla_dom_SVGAnimatedEnumeration_h
+#ifndef mozilla_dom_DOMSVGAnimatedEnumeration_h
+#define mozilla_dom_DOMSVGAnimatedEnumeration_h
 
 #include "nsWrapperCache.h"
 
 #include "SVGElement.h"
 
 namespace mozilla {
 namespace dom {
 
-class SVGAnimatedEnumeration : public nsISupports, public nsWrapperCache {
+class DOMSVGAnimatedEnumeration : public nsISupports, public nsWrapperCache {
  public:
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
-  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(SVGAnimatedEnumeration)
+  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(DOMSVGAnimatedEnumeration)
 
   SVGElement* GetParentObject() const { return mSVGElement; }
 
   JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) final;
 
   virtual uint16_t BaseVal() = 0;
   virtual void SetBaseVal(uint16_t aBaseVal, ErrorResult& aRv) = 0;
   virtual uint16_t AnimVal() = 0;
 
  protected:
-  explicit SVGAnimatedEnumeration(SVGElement* aSVGElement)
+  explicit DOMSVGAnimatedEnumeration(SVGElement* aSVGElement)
       : mSVGElement(aSVGElement) {}
-  virtual ~SVGAnimatedEnumeration(){};
+  virtual ~DOMSVGAnimatedEnumeration(){};
 
   RefPtr<SVGElement> mSVGElement;
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
-#endif  // mozilla_dom_SVGAnimatedEnumeration_h
+#endif  // mozilla_dom_DOMSVGAnimatedEnumeration_h
rename from dom/svg/SVGAnimatedInteger.cpp
rename to dom/svg/DOMSVGAnimatedInteger.cpp
--- a/dom/svg/SVGAnimatedInteger.cpp
+++ b/dom/svg/DOMSVGAnimatedInteger.cpp
@@ -1,30 +1,31 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#include "mozilla/dom/SVGAnimatedInteger.h"
+#include "DOMSVGAnimatedInteger.h"
 
 #include "mozilla/dom/SVGAnimatedIntegerBinding.h"
 
 namespace mozilla {
 namespace dom {
 
-NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(SVGAnimatedInteger, mSVGElement)
+NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(DOMSVGAnimatedInteger,
+                                               mSVGElement)
 
-NS_IMPL_CYCLE_COLLECTING_ADDREF(SVGAnimatedInteger)
-NS_IMPL_CYCLE_COLLECTING_RELEASE(SVGAnimatedInteger)
+NS_IMPL_CYCLE_COLLECTING_ADDREF(DOMSVGAnimatedInteger)
+NS_IMPL_CYCLE_COLLECTING_RELEASE(DOMSVGAnimatedInteger)
 
-NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(SVGAnimatedInteger)
+NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(DOMSVGAnimatedInteger)
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
   NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
-JSObject* SVGAnimatedInteger::WrapObject(JSContext* aCx,
-                                         JS::Handle<JSObject*> aGivenProto) {
+JSObject* DOMSVGAnimatedInteger::WrapObject(JSContext* aCx,
+                                            JS::Handle<JSObject*> aGivenProto) {
   return SVGAnimatedInteger_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 }  // namespace dom
 }  // namespace mozilla
rename from dom/svg/SVGAnimatedInteger.h
rename to dom/svg/DOMSVGAnimatedInteger.h
--- a/dom/svg/SVGAnimatedInteger.h
+++ b/dom/svg/DOMSVGAnimatedInteger.h
@@ -1,41 +1,41 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#ifndef mozilla_dom_SVGAnimatedInteger_h
-#define mozilla_dom_SVGAnimatedInteger_h
+#ifndef mozilla_dom_DOMSVGAnimatedInteger_h
+#define mozilla_dom_DOMSVGAnimatedInteger_h
 
 #include "nsWrapperCache.h"
 
 #include "SVGElement.h"
 
 namespace mozilla {
 namespace dom {
 
-class SVGAnimatedInteger : public nsISupports, public nsWrapperCache {
+class DOMSVGAnimatedInteger : public nsISupports, public nsWrapperCache {
  public:
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
-  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(SVGAnimatedInteger)
+  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(DOMSVGAnimatedInteger)
 
   SVGElement* GetParentObject() const { return mSVGElement; }
 
   JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) final;
 
   virtual int32_t BaseVal() = 0;
   virtual void SetBaseVal(int32_t aBaseVal) = 0;
   virtual int32_t AnimVal() = 0;
 
  protected:
-  explicit SVGAnimatedInteger(SVGElement* aSVGElement)
+  explicit DOMSVGAnimatedInteger(SVGElement* aSVGElement)
       : mSVGElement(aSVGElement) {}
-  virtual ~SVGAnimatedInteger(){};
+  virtual ~DOMSVGAnimatedInteger(){};
 
   RefPtr<SVGElement> mSVGElement;
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
-#endif  // mozilla_dom_SVGAnimatedInteger_h
+#endif  // mozilla_dom_DOMSVGAnimatedInteger_h
rename from dom/svg/SVGAnimatedLength.cpp
rename to dom/svg/DOMSVGAnimatedLength.cpp
--- a/dom/svg/SVGAnimatedLength.cpp
+++ b/dom/svg/DOMSVGAnimatedLength.cpp
@@ -1,34 +1,36 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#include "mozilla/dom/SVGAnimatedLength.h"
+#include "DOMSVGAnimatedLength.h"
+
 #include "mozilla/dom/SVGAnimatedLengthBinding.h"
 #include "nsSVGLength2.h"
 #include "DOMSVGLength.h"
 
 namespace mozilla {
 namespace dom {
 
-NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(SVGAnimatedLength, mSVGElement)
+NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(DOMSVGAnimatedLength,
+                                               mSVGElement)
 
-NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(SVGAnimatedLength, AddRef)
-NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(SVGAnimatedLength, Release)
+NS_IMPL_CYCLE_COLLECTION_ROOT_NATIVE(DOMSVGAnimatedLength, AddRef)
+NS_IMPL_CYCLE_COLLECTION_UNROOT_NATIVE(DOMSVGAnimatedLength, Release)
 
-JSObject* SVGAnimatedLength::WrapObject(JSContext* aCx,
-                                        JS::Handle<JSObject*> aGivenProto) {
+JSObject* DOMSVGAnimatedLength::WrapObject(JSContext* aCx,
+                                           JS::Handle<JSObject*> aGivenProto) {
   return SVGAnimatedLength_Binding::Wrap(aCx, this, aGivenProto);
 }
 
-already_AddRefed<DOMSVGLength> SVGAnimatedLength::BaseVal() {
+already_AddRefed<DOMSVGLength> DOMSVGAnimatedLength::BaseVal() {
   return mVal->ToDOMBaseVal(mSVGElement);
 }
 
-already_AddRefed<DOMSVGLength> SVGAnimatedLength::AnimVal() {
+already_AddRefed<DOMSVGLength> DOMSVGAnimatedLength::AnimVal() {
   return mVal->ToDOMAnimVal(mSVGElement);
 }
 
 }  // namespace dom
 }  // namespace mozilla
rename from dom/svg/SVGAnimatedLength.h
rename to dom/svg/DOMSVGAnimatedLength.h
--- a/dom/svg/SVGAnimatedLength.h
+++ b/dom/svg/DOMSVGAnimatedLength.h
@@ -1,46 +1,46 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#ifndef mozilla_dom_SVGAnimatedLength_h
-#define mozilla_dom_SVGAnimatedLength_h
+#ifndef mozilla_dom_DOMSVGAnimatedLength_h
+#define mozilla_dom_DOMSVGAnimatedLength_h
 
 #include "mozilla/Attributes.h"
 #include "SVGElement.h"
 
 class nsSVGLength2;
 
 namespace mozilla {
 
 namespace dom {
 
 class DOMSVGLength;
 
-class SVGAnimatedLength final : public nsWrapperCache {
+class DOMSVGAnimatedLength final : public nsWrapperCache {
  public:
-  NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(SVGAnimatedLength)
-  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(SVGAnimatedLength)
+  NS_INLINE_DECL_CYCLE_COLLECTING_NATIVE_REFCOUNTING(DOMSVGAnimatedLength)
+  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_NATIVE_CLASS(DOMSVGAnimatedLength)
 
-  SVGAnimatedLength(nsSVGLength2* aVal, SVGElement* aSVGElement)
+  DOMSVGAnimatedLength(nsSVGLength2* aVal, SVGElement* aSVGElement)
       : mVal(aVal), mSVGElement(aSVGElement) {}
 
   // WebIDL
   SVGElement* GetParentObject() { return mSVGElement; }
   virtual JSObject* WrapObject(JSContext* aCx,
                                JS::Handle<JSObject*> aGivenProto) override;
   already_AddRefed<DOMSVGLength> BaseVal();
   already_AddRefed<DOMSVGLength> AnimVal();
 
  protected:
-  ~SVGAnimatedLength();
+  ~DOMSVGAnimatedLength();
 
   nsSVGLength2* mVal;  // kept alive because it belongs to content
   RefPtr<SVGElement> mSVGElement;
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
-#endif  // mozilla_dom_SVGAnimatedLength_h
+#endif  // mozilla_dom_DOMSVGAnimatedLength_h
rename from dom/svg/SVGAnimatedNumber.cpp
rename to dom/svg/DOMSVGAnimatedNumber.cpp
--- a/dom/svg/SVGAnimatedNumber.cpp
+++ b/dom/svg/DOMSVGAnimatedNumber.cpp
@@ -1,30 +1,31 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#include "mozilla/dom/SVGAnimatedNumber.h"
+#include "DOMSVGAnimatedNumber.h"
 
 #include "mozilla/dom/SVGAnimatedNumberBinding.h"
 
 namespace mozilla {
 namespace dom {
 
-NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(SVGAnimatedNumber, mSVGElement)
+NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPERCACHED(DOMSVGAnimatedNumber,
+                                               mSVGElement)
 
-NS_IMPL_CYCLE_COLLECTING_ADDREF(SVGAnimatedNumber)
-NS_IMPL_CYCLE_COLLECTING_RELEASE(SVGAnimatedNumber)
+NS_IMPL_CYCLE_COLLECTING_ADDREF(DOMSVGAnimatedNumber)
+NS_IMPL_CYCLE_COLLECTING_RELEASE(DOMSVGAnimatedNumber)
 
-NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(SVGAnimatedNumber)
+NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(DOMSVGAnimatedNumber)
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
   NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
-JSObject* SVGAnimatedNumber::WrapObject(JSContext* aCx,
-                                        JS::Handle<JSObject*> aGivenProto) {
+JSObject* DOMSVGAnimatedNumber::WrapObject(JSContext* aCx,
+                                           JS::Handle<JSObject*> aGivenProto) {
   return SVGAnimatedNumber_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 }  // namespace dom
 }  // namespace mozilla
rename from dom/svg/SVGAnimatedNumber.h
rename to dom/svg/DOMSVGAnimatedNumber.h
--- a/dom/svg/SVGAnimatedNumber.h
+++ b/dom/svg/DOMSVGAnimatedNumber.h
@@ -1,42 +1,42 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#ifndef mozilla_dom_SVGAnimatedNumber_h
-#define mozilla_dom_SVGAnimatedNumber_h
+#ifndef mozilla_dom_DOMSVGAnimatedNumber_h
+#define mozilla_dom_DOMSVGAnimatedNumber_h
 
 #include "nsISupports.h"
 #include "nsWrapperCache.h"
 
 #include "SVGElement.h"
 
 namespace mozilla {
 namespace dom {
 
-class SVGAnimatedNumber : public nsISupports, public nsWrapperCache {
+class DOMSVGAnimatedNumber : public nsISupports, public nsWrapperCache {
  public:
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
-  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(SVGAnimatedNumber)
+  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(DOMSVGAnimatedNumber)
 
   SVGElement* GetParentObject() const { return mSVGElement; }
 
   JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) final;
 
   virtual float BaseVal() = 0;
   virtual void SetBaseVal(float aBaseVal) = 0;
   virtual float AnimVal() = 0;
 
  protected:
-  explicit SVGAnimatedNumber(SVGElement* aSVGElement)
+  explicit DOMSVGAnimatedNumber(SVGElement* aSVGElement)
       : mSVGElement(aSVGElement) {}
-  virtual ~SVGAnimatedNumber(){};
+  virtual ~DOMSVGAnimatedNumber(){};
 
   RefPtr<SVGElement> mSVGElement;
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
-#endif  // mozilla_dom_SVGAnimatedNumber_h
+#endif  // mozilla_dom_DOMSVGAnimatedNumber_h
rename from dom/svg/SVGAnimatedString.cpp
rename to dom/svg/DOMSVGAnimatedString.cpp
--- a/dom/svg/SVGAnimatedString.cpp
+++ b/dom/svg/DOMSVGAnimatedString.cpp
@@ -1,19 +1,20 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#include "mozilla/dom/SVGAnimatedString.h"
+#include "DOMSVGAnimatedString.h"
+
 #include "mozilla/dom/SVGAnimatedStringBinding.h"
 
 namespace mozilla {
 namespace dom {
 
-JSObject* SVGAnimatedString::WrapObject(JSContext* aCx,
-                                        JS::Handle<JSObject*> aGivenProto) {
+JSObject* DOMSVGAnimatedString::WrapObject(JSContext* aCx,
+                                           JS::Handle<JSObject*> aGivenProto) {
   return SVGAnimatedString_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 }  // namespace dom
 }  // namespace mozilla
rename from dom/svg/SVGAnimatedString.h
rename to dom/svg/DOMSVGAnimatedString.h
--- a/dom/svg/SVGAnimatedString.h
+++ b/dom/svg/DOMSVGAnimatedString.h
@@ -1,25 +1,25 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
-#ifndef mozilla_dom_SVGAnimatedString_h
-#define mozilla_dom_SVGAnimatedString_h
+#ifndef mozilla_dom_DOMSVGAnimatedString_h
+#define mozilla_dom_DOMSVGAnimatedString_h
 
 #include "SVGElement.h"
 
 namespace mozilla {
 namespace dom {
 
-class SVGAnimatedString : public nsISupports, public nsWrapperCache {
+class DOMSVGAnimatedString : public nsISupports, public nsWrapperCache {
  public:
-  explicit SVGAnimatedString(SVGElement* aSVGElement)
+  explicit DOMSVGAnimatedString(SVGElement* aSVGElement)
       : mSVGElement(aSVGElement) {}
 
   virtual JSObject* WrapObject(JSContext* aCx,
                                JS::Handle<JSObject*> aGivenProto) override;
 
   // WebIDL
   SVGElement* GetParentObject() const { return mSVGElement; }
 
@@ -28,9 +28,9 @@ class SVGAnimatedString : public nsISupp
   virtual void GetAnimVal(nsAString& aResult) = 0;
 
   RefPtr<SVGElement> mSVGElement;
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
-#endif  // mozilla_dom_SVGAnimatedString_h
+#endif  // mozilla_dom_DOMSVGAnimatedString_h
--- a/dom/svg/DOMSVGTransformList.cpp
+++ b/dom/svg/DOMSVGTransformList.cpp
@@ -1,20 +1,20 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #include "DOMSVGTransformList.h"
 
-#include "mozilla/dom/DOMSVGTransform.h"
 #include "mozilla/dom/SVGElement.h"
 #include "mozilla/dom/SVGMatrix.h"
 #include "mozilla/dom/SVGTransformListBinding.h"
+#include "DOMSVGTransform.h"
 #include "SVGAnimatedTransformList.h"
 #include "nsError.h"
 #include <algorithm>
 
 // local helper functions
 namespace {
 
 void UpdateListIndicesFromIndex(
--- a/dom/svg/SVGAElement.cpp
+++ b/dom/svg/SVGAElement.cpp
@@ -50,17 +50,17 @@ NS_IMPL_RELEASE_INHERITED(SVGAElement, S
 //----------------------------------------------------------------------
 // Implementation
 
 SVGAElement::SVGAElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
     : SVGAElementBase(std::move(aNodeInfo)), Link(this) {}
 
 SVGAElement::~SVGAElement() {}
 
-already_AddRefed<SVGAnimatedString> SVGAElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGAElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // Link methods
 
@@ -81,17 +81,17 @@ void SVGAElement::GetEventTargetParent(E
 nsresult SVGAElement::PostHandleEvent(EventChainPostVisitor& aVisitor) {
   return PostHandleEventForLinks(aVisitor);
 }
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGAElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedString> SVGAElement::Target() {
+already_AddRefed<DOMSVGAnimatedString> SVGAElement::Target() {
   return mStringAttributes[TARGET].ToDOMAnimatedString(this);
 }
 
 void SVGAElement::GetDownload(nsAString& aDownload) {
   GetAttr(nsGkAtoms::download, aDownload);
 }
 
 void SVGAElement::SetDownload(const nsAString& aDownload, ErrorResult& rv) {
--- a/dom/svg/SVGAElement.h
+++ b/dom/svg/SVGAElement.h
@@ -62,18 +62,18 @@ class SVGAElement final : public SVGAEle
                                 const nsAttrValue* aOldValue,
                                 nsIPrincipal* aMaybeScriptedPrincipal,
                                 bool aNotify) override;
 
   // Link
   virtual bool ElementHasHref() const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> Href();
-  already_AddRefed<SVGAnimatedString> Target();
+  already_AddRefed<DOMSVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedString> Target();
   void GetDownload(nsAString& aDownload);
   void SetDownload(const nsAString& aDownload, ErrorResult& rv);
   void GetPing(nsAString& aPing);
   void SetPing(const nsAString& aPing, mozilla::ErrorResult& rv);
   void GetRel(nsAString& aRel);
   void SetRel(const nsAString& aRel, mozilla::ErrorResult& rv);
   void SetReferrerPolicy(const nsAString& aReferrerPolicy,
                          mozilla::ErrorResult& rv);
--- a/dom/svg/SVGBoolean.cpp
+++ b/dom/svg/SVGBoolean.cpp
@@ -1,31 +1,31 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #include "SVGBoolean.h"
 
+#include "DOMSVGAnimatedBoolean.h"
 #include "nsError.h"
 #include "SMILBoolType.h"
 #include "SVGAttrTearoffTable.h"
 #include "mozilla/SMILValue.h"
-#include "mozilla/dom/SVGAnimatedBoolean.h"
 
 using namespace mozilla::dom;
 
 namespace mozilla {
 
 /* Implementation */
 
-static inline SVGAttrTearoffTable<SVGBoolean, SVGAnimatedBoolean>&
+static inline SVGAttrTearoffTable<SVGBoolean, DOMSVGAnimatedBoolean>&
 SVGAnimatedBooleanTearoffTable() {
-  static SVGAttrTearoffTable<SVGBoolean, SVGAnimatedBoolean>
+  static SVGAttrTearoffTable<SVGBoolean, DOMSVGAnimatedBoolean>
       sSVGAnimatedBooleanTearoffTable;
   return sSVGAnimatedBooleanTearoffTable;
 }
 
 static bool GetValueFromString(const nsAString& aValueAsString, bool& aValue) {
   if (aValueAsString.EqualsLiteral("true")) {
     aValue = true;
     return true;
@@ -93,29 +93,29 @@ void SVGBoolean::SetAnimValue(bool aValu
   if (mIsAnimated && mAnimVal == aValue) {
     return;
   }
   mAnimVal = aValue;
   mIsAnimated = true;
   aSVGElement->DidAnimateBoolean(mAttrEnum);
 }
 
-already_AddRefed<SVGAnimatedBoolean> SVGBoolean::ToDOMAnimatedBoolean(
+already_AddRefed<DOMSVGAnimatedBoolean> SVGBoolean::ToDOMAnimatedBoolean(
     SVGElement* aSVGElement) {
-  RefPtr<SVGAnimatedBoolean> domAnimatedBoolean =
+  RefPtr<DOMSVGAnimatedBoolean> domAnimatedBoolean =
       SVGAnimatedBooleanTearoffTable().GetTearoff(this);
   if (!domAnimatedBoolean) {
-    domAnimatedBoolean = new SVGAnimatedBoolean(this, aSVGElement);
+    domAnimatedBoolean = new DOMSVGAnimatedBoolean(this, aSVGElement);
     SVGAnimatedBooleanTearoffTable().AddTearoff(this, domAnimatedBoolean);
   }
 
   return domAnimatedBoolean.forget();
 }
 
-SVGAnimatedBoolean::~SVGAnimatedBoolean() {
+DOMSVGAnimatedBoolean::~DOMSVGAnimatedBoolean() {
   SVGAnimatedBooleanTearoffTable().RemoveTearoff(mVal);
 }
 
 UniquePtr<SMILAttr> SVGBoolean::ToSMILAttr(SVGElement* aSVGElement) {
   return MakeUnique<SMILBool>(this, aSVGElement);
 }
 
 nsresult SVGBoolean::SMILBool::ValueFromString(
--- a/dom/svg/SVGBoolean.h
+++ b/dom/svg/SVGBoolean.h
@@ -15,18 +15,18 @@
 
 class nsAtom;
 
 namespace mozilla {
 
 class SMILValue;
 
 namespace dom {
+class DOMSVGAnimatedBoolean;
 class SVGAnimationElement;
-class SVGAnimatedBoolean;
 class SVGElement;
 }  // namespace dom
 
 class SVGBoolean {
  public:
   typedef mozilla::dom::SVGElement SVGElement;
 
   void Init(uint8_t aAttrEnum = 0xff, bool aValue = false) {
@@ -39,17 +39,17 @@ class SVGBoolean {
   nsAtom* GetBaseValueAtom() const;
 
   void SetBaseValue(bool aValue, SVGElement* aSVGElement);
   bool GetBaseValue() const { return mBaseVal; }
 
   void SetAnimValue(bool aValue, SVGElement* aSVGElement);
   bool GetAnimValue() const { return mAnimVal; }
 
-  already_AddRefed<mozilla::dom::SVGAnimatedBoolean> ToDOMAnimatedBoolean(
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedBoolean> ToDOMAnimatedBoolean(
       SVGElement* aSVGElement);
   mozilla::UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
  private:
   bool mAnimVal;
   bool mBaseVal;
   bool mIsAnimated;
   uint8_t mAttrEnum;  // element specified tracking for attribute
--- a/dom/svg/SVGCircleElement.cpp
+++ b/dom/svg/SVGCircleElement.cpp
@@ -39,25 +39,25 @@ SVGCircleElement::SVGCircleElement(
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGCircleElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGCircleElement::Cx() {
+already_AddRefed<DOMSVGAnimatedLength> SVGCircleElement::Cx() {
   return mLengthAttributes[ATTR_CX].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGCircleElement::Cy() {
+already_AddRefed<DOMSVGAnimatedLength> SVGCircleElement::Cy() {
   return mLengthAttributes[ATTR_CY].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGCircleElement::R() {
+already_AddRefed<DOMSVGAnimatedLength> SVGCircleElement::R() {
   return mLengthAttributes[ATTR_R].ToDOMAnimatedLength(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 /* virtual */
 bool SVGCircleElement::HasValidDimensions() const {
--- a/dom/svg/SVGCircleElement.h
+++ b/dom/svg/SVGCircleElement.h
@@ -37,19 +37,19 @@ class SVGCircleElement final : public SV
       Rect* aBounds, const StrokeOptions& aStrokeOptions,
       const Matrix& aToBoundsSpace,
       const Matrix* aToNonScalingStrokeSpace = nullptr) override;
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> Cx();
-  already_AddRefed<SVGAnimatedLength> Cy();
-  already_AddRefed<SVGAnimatedLength> R();
+  already_AddRefed<DOMSVGAnimatedLength> Cx();
+  already_AddRefed<DOMSVGAnimatedLength> Cy();
+  already_AddRefed<DOMSVGAnimatedLength> R();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
 
   enum { ATTR_CX, ATTR_CY, ATTR_R };
   nsSVGLength2 mLengthAttributes[3];
   static LengthInfo sLengthInfo[3];
 };
--- a/dom/svg/SVGClass.cpp
+++ b/dom/svg/SVGClass.cpp
@@ -1,31 +1,33 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #include "SVGClass.h"
 
-#include "mozilla/dom/SVGAnimatedString.h"
 #include "mozilla/dom/SVGElement.h"
 #include "mozilla/Move.h"
 #include "mozilla/SMILValue.h"
+#include "DOMSVGAnimatedString.h"
 #include "SMILStringType.h"
 
 namespace mozilla {
 namespace dom {
 
-struct DOMAnimatedString final : public SVGAnimatedString {
+// DOM wrapper class for the (DOM)SVGAnimatedString interface where the
+// wrapped class is SVGClass.
+struct DOMAnimatedString final : public DOMSVGAnimatedString {
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
   NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(DOMAnimatedString)
 
   DOMAnimatedString(SVGClass* aVal, SVGElement* aSVGElement)
-      : SVGAnimatedString(aSVGElement), mVal(aVal) {}
+      : DOMSVGAnimatedString(aSVGElement), mVal(aVal) {}
 
   SVGClass* mVal;  // kept alive because it belongs to content
 
   void GetBaseVal(nsAString& aResult) override {
     mVal->GetBaseValue(aResult, mSVGElement);
   }
 
   void SetBaseVal(const nsAString& aValue) override {
@@ -43,17 +45,17 @@ NS_SVG_VAL_IMPL_CYCLE_COLLECTION_WRAPPER
 NS_IMPL_CYCLE_COLLECTING_ADDREF(DOMAnimatedString)
 NS_IMPL_CYCLE_COLLECTING_RELEASE(DOMAnimatedString)
 
 NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(DOMAnimatedString)
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
   NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
-already_AddRefed<SVGAnimatedString> SVGClass::ToDOMAnimatedString(
+already_AddRefed<DOMSVGAnimatedString> SVGClass::ToDOMAnimatedString(
     SVGElement* aSVGElement) {
   RefPtr<DOMAnimatedString> result = new DOMAnimatedString(this, aSVGElement);
   return result.forget();
 }
 
 /* Implementation */
 
 void SVGClass::SetBaseValue(const nsAString& aValue, SVGElement* aSVGElement,
--- a/dom/svg/SVGClass.h
+++ b/dom/svg/SVGClass.h
@@ -15,34 +15,34 @@
 #include "mozilla/SMILAttr.h"
 #include "mozilla/UniquePtr.h"
 
 namespace mozilla {
 
 class SMILValue;
 
 namespace dom {
-class SVGAnimatedString;
+class DOMSVGAnimatedString;
 class SVGElement;
 
 class SVGClass {
  public:
   typedef mozilla::dom::SVGElement SVGElement;
 
   void Init() { mAnimVal = nullptr; }
 
   void SetBaseValue(const nsAString& aValue, SVGElement* aSVGElement,
                     bool aDoSetAttr);
   void GetBaseValue(nsAString& aValue, const SVGElement* aSVGElement) const;
 
   void SetAnimValue(const nsAString& aValue, SVGElement* aSVGElement);
   void GetAnimValue(nsAString& aValue, const SVGElement* aSVGElement) const;
   bool IsAnimated() const { return !!mAnimVal; }
 
-  already_AddRefed<mozilla::dom::SVGAnimatedString> ToDOMAnimatedString(
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedString> ToDOMAnimatedString(
       SVGElement* aSVGElement);
 
   mozilla::UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
  private:
   nsAutoPtr<nsString> mAnimVal;
 
  public:
--- a/dom/svg/SVGClipPathElement.cpp
+++ b/dom/svg/SVGClipPathElement.cpp
@@ -28,17 +28,18 @@ SVGElement::EnumInfo SVGClipPathElement:
 
 //----------------------------------------------------------------------
 // Implementation
 
 SVGClipPathElement::SVGClipPathElement(
     already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
     : SVGClipPathElementBase(std::move(aNodeInfo)) {}
 
-already_AddRefed<SVGAnimatedEnumeration> SVGClipPathElement::ClipPathUnits() {
+already_AddRefed<DOMSVGAnimatedEnumeration>
+SVGClipPathElement::ClipPathUnits() {
   return mEnumAttributes[CLIPPATHUNITS].ToDOMAnimatedEnum(this);
 }
 
 SVGElement::EnumAttributesInfo SVGClipPathElement::GetEnumInfo() {
   return EnumAttributesInfo(mEnumAttributes, sEnumInfo, ArrayLength(sEnumInfo));
 }
 
 bool SVGClipPathElement::IsUnitsObjectBoundingBox() const {
--- a/dom/svg/SVGClipPathElement.h
+++ b/dom/svg/SVGClipPathElement.h
@@ -31,17 +31,17 @@ class SVGClipPathElement final : public 
       already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
   virtual JSObject* WrapNode(JSContext* cx,
                              JS::Handle<JSObject*> aGivenProto) override;
 
  public:
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedEnumeration> ClipPathUnits();
+  already_AddRefed<DOMSVGAnimatedEnumeration> ClipPathUnits();
 
   // This is an internal method that does not flush style, and thus
   // the answer may be out of date if there's a pending style flush.
   bool IsUnitsObjectBoundingBox() const;
 
  protected:
   enum { CLIPPATHUNITS };
   SVGEnum mEnumAttributes[1];
--- a/dom/svg/SVGComponentTransferFunctionElement.h
+++ b/dom/svg/SVGComponentTransferFunctionElement.h
@@ -51,23 +51,23 @@ class SVGComponentTransferFunctionElemen
   virtual int32_t GetChannel() = 0;
 
   void ComputeAttributes(int32_t aChannel,
                          ComponentTransferAttributes& aAttributes);
 
   // WebIDL
   virtual JSObject* WrapNode(JSContext* aCx,
                              JS::Handle<JSObject*> aGivenProto) override = 0;
-  already_AddRefed<SVGAnimatedEnumeration> Type();
+  already_AddRefed<DOMSVGAnimatedEnumeration> Type();
   already_AddRefed<DOMSVGAnimatedNumberList> TableValues();
-  already_AddRefed<SVGAnimatedNumber> Slope();
-  already_AddRefed<SVGAnimatedNumber> Intercept();
-  already_AddRefed<SVGAnimatedNumber> Amplitude();
-  already_AddRefed<SVGAnimatedNumber> Exponent();
-  already_AddRefed<SVGAnimatedNumber> Offset();
+  already_AddRefed<DOMSVGAnimatedNumber> Slope();
+  already_AddRefed<DOMSVGAnimatedNumber> Intercept();
+  already_AddRefed<DOMSVGAnimatedNumber> Amplitude();
+  already_AddRefed<DOMSVGAnimatedNumber> Exponent();
+  already_AddRefed<DOMSVGAnimatedNumber> Offset();
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual NumberListAttributesInfo GetNumberListInfo() override;
 
   enum { TABLEVALUES };
   SVGAnimatedNumberList mNumberListAttributes[1];
--- a/dom/svg/SVGElement.cpp
+++ b/dom/svg/SVGElement.cpp
@@ -2,17 +2,16 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #include "mozilla/dom/SVGElement.h"
 
 #include "mozilla/dom/MutationEventBinding.h"
-#include "mozilla/dom/SVGAnimatedEnumeration.h"
 #include "mozilla/dom/SVGElementBinding.h"
 #include "mozilla/dom/SVGGeometryElement.h"
 #include "mozilla/dom/SVGLengthBinding.h"
 #include "mozilla/dom/SVGSVGElement.h"
 #include "mozilla/dom/SVGTests.h"
 #include "mozilla/dom/SVGUnitTypesBinding.h"
 
 #include "mozilla/ArrayUtils.h"
@@ -20,16 +19,17 @@
 #include "mozilla/DeclarationBlock.h"
 #include "mozilla/EventListenerManager.h"
 #include "mozilla/InternalMutationEvent.h"
 #include "mozilla/RestyleManager.h"
 #include "mozilla/SMILAnimationController.h"
 #include "mozilla/SVGContentUtils.h"
 #include "mozilla/Unused.h"
 
+#include "DOMSVGAnimatedEnumeration.h"
 #include "mozAutoDocUpdate.h"
 #include "nsAttrValueOrString.h"
 #include "nsCSSProps.h"
 #include "nsContentUtils.h"
 #include "nsICSSDeclaration.h"
 #include "nsIContentInlines.h"
 #include "mozilla/dom/Document.h"
 #include "nsError.h"
@@ -1011,17 +1011,17 @@ SVGSVGElement* SVGElement::GetOwnerSVGEl
   // we don't have an ancestor <svg> element...
   return nullptr;
 }
 
 SVGElement* SVGElement::GetViewportElement() {
   return SVGContentUtils::GetNearestViewportElement(this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGElement::ClassName() {
+already_AddRefed<DOMSVGAnimatedString> SVGElement::ClassName() {
   return mClassAttribute.ToDOMAnimatedString(this);
 }
 
 //------------------------------------------------------------------------
 // Helper class: MappedAttrParser, for parsing values of mapped attributes
 
 namespace {
 
@@ -2221,17 +2221,16 @@ UniquePtr<SMILAttr> SVGElement::GetAnima
     }
 
     // orient:
     if (aName == nsGkAtoms::orient) {
       SVGOrient* orient = GetOrient();
       return orient ? orient->ToSMILAttr(this) : nullptr;
     }
 
-    // preserveAspectRatio:
     // viewBox:
     if (aName == nsGkAtoms::viewBox) {
       SVGViewBox* viewBox = GetViewBox();
       return viewBox ? viewBox->ToSMILAttr(this) : nullptr;
     }
 
     // preserveAspectRatio:
     if (aName == nsGkAtoms::preserveAspectRatio) {
--- a/dom/svg/SVGElement.h
+++ b/dom/svg/SVGElement.h
@@ -298,17 +298,17 @@ class SVGElement : public SVGElementBase
   }
 
   virtual void ClearAnyCachedPath() {}
   virtual bool IsTransformable() { return false; }
 
   // WebIDL
   mozilla::dom::SVGSVGElement* GetOwnerSVGElement();
   SVGElement* GetViewportElement();
-  already_AddRefed<mozilla::dom::SVGAnimatedString> ClassName();
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedString> ClassName();
 
   void UpdateContentDeclarationBlock();
   const mozilla::DeclarationBlock* GetContentDeclarationBlock() const;
 
  protected:
   virtual JSObject* WrapNode(JSContext* cx,
                              JS::Handle<JSObject*> aGivenProto) override;
 
--- a/dom/svg/SVGEllipseElement.cpp
+++ b/dom/svg/SVGEllipseElement.cpp
@@ -44,29 +44,29 @@ SVGEllipseElement::SVGEllipseElement(
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGEllipseElement)
 
 //----------------------------------------------------------------------
 // nsIDOMSVGEllipseElement methods
 
-already_AddRefed<SVGAnimatedLength> SVGEllipseElement::Cx() {
+already_AddRefed<DOMSVGAnimatedLength> SVGEllipseElement::Cx() {
   return mLengthAttributes[CX].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGEllipseElement::Cy() {
+already_AddRefed<DOMSVGAnimatedLength> SVGEllipseElement::Cy() {
   return mLengthAttributes[CY].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGEllipseElement::Rx() {
+already_AddRefed<DOMSVGAnimatedLength> SVGEllipseElement::Rx() {
   return mLengthAttributes[RX].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGEllipseElement::Ry() {
+already_AddRefed<DOMSVGAnimatedLength> SVGEllipseElement::Ry() {
   return mLengthAttributes[RY].ToDOMAnimatedLength(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 /* virtual */
 bool SVGEllipseElement::HasValidDimensions() const {
--- a/dom/svg/SVGEllipseElement.h
+++ b/dom/svg/SVGEllipseElement.h
@@ -37,20 +37,20 @@ class SVGEllipseElement final : public S
       Rect* aBounds, const StrokeOptions& aStrokeOptions,
       const Matrix& aToBoundsSpace,
       const Matrix* aToNonScalingStrokeSpace = nullptr) override;
   virtual already_AddRefed<Path> BuildPath(PathBuilder* aBuilder) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> Cx();
-  already_AddRefed<SVGAnimatedLength> Cy();
-  already_AddRefed<SVGAnimatedLength> Rx();
-  already_AddRefed<SVGAnimatedLength> Ry();
+  already_AddRefed<DOMSVGAnimatedLength> Cx();
+  already_AddRefed<DOMSVGAnimatedLength> Cy();
+  already_AddRefed<DOMSVGAnimatedLength> Rx();
+  already_AddRefed<DOMSVGAnimatedLength> Ry();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
 
   enum { CX, CY, RX, RY };
   nsSVGLength2 mLengthAttributes[4];
   static LengthInfo sLengthInfo[4];
 };
--- a/dom/svg/SVGEnum.cpp
+++ b/dom/svg/SVGEnum.cpp
@@ -94,17 +94,17 @@ void SVGEnum::SetAnimValue(uint16_t aVal
   if (mIsAnimated && aValue == mAnimVal) {
     return;
   }
   mAnimVal = aValue;
   mIsAnimated = true;
   aSVGElement->DidAnimateEnum(mAttrEnum);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGEnum::ToDOMAnimatedEnum(
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGEnum::ToDOMAnimatedEnum(
     SVGElement* aSVGElement) {
   RefPtr<DOMAnimatedEnum> domAnimatedEnum =
       sSVGAnimatedEnumTearoffTable.GetTearoff(this);
   if (!domAnimatedEnum) {
     domAnimatedEnum = new DOMAnimatedEnum(this, aSVGElement);
     sSVGAnimatedEnumTearoffTable.AddTearoff(this, domAnimatedEnum);
   }
 
--- a/dom/svg/SVGEnum.h
+++ b/dom/svg/SVGEnum.h
@@ -2,22 +2,22 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef __NS_SVGENUM_H__
 #define __NS_SVGENUM_H__
 
+#include "DOMSVGAnimatedEnumeration.h"
 #include "nsCycleCollectionParticipant.h"
 #include "nsError.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/SMILAttr.h"
 #include "mozilla/UniquePtr.h"
-#include "mozilla/dom/SVGAnimatedEnumeration.h"
 #include "mozilla/dom/SVGElement.h"
 
 class nsAtom;
 
 namespace mozilla {
 
 class SMILValue;
 
@@ -47,39 +47,42 @@ class SVGEnum {
   nsAtom* GetBaseValueAtom(SVGElement* aSVGElement);
   nsresult SetBaseValue(uint16_t aValue, SVGElement* aSVGElement);
   uint16_t GetBaseValue() const { return mBaseVal; }
 
   void SetAnimValue(uint16_t aValue, SVGElement* aSVGElement);
   uint16_t GetAnimValue() const { return mAnimVal; }
   bool IsExplicitlySet() const { return mIsAnimated || mIsBaseSet; }
 
-  already_AddRefed<mozilla::dom::SVGAnimatedEnumeration> ToDOMAnimatedEnum(
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedEnumeration> ToDOMAnimatedEnum(
       SVGElement* aSVGElement);
 
   mozilla::UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
  private:
   SVGEnumValue mAnimVal;
   SVGEnumValue mBaseVal;
   uint8_t mAttrEnum;  // element specified tracking for attribute
   bool mIsAnimated;
   bool mIsBaseSet;
 
   const SVGEnumMapping* GetMapping(SVGElement* aSVGElement);
 
  public:
-  struct DOMAnimatedEnum final : public mozilla::dom::SVGAnimatedEnumeration {
+  // DOM wrapper class for the (DOM)SVGAnimatedEnumeration interface where the
+  // wrapped class is SVGEnum.
+  struct DOMAnimatedEnum final
+      : public mozilla::dom::DOMSVGAnimatedEnumeration {
     DOMAnimatedEnum(SVGEnum* aVal, SVGElement* aSVGElement)
-        : mozilla::dom::SVGAnimatedEnumeration(aSVGElement), mVal(aVal) {}
+        : mozilla::dom::DOMSVGAnimatedEnumeration(aSVGElement), mVal(aVal) {}
     virtual ~DOMAnimatedEnum();
 
     SVGEnum* mVal;  // kept alive because it belongs to content
 
-    using mozilla::dom::SVGAnimatedEnumeration::SetBaseVal;
+    using mozilla::dom::DOMSVGAnimatedEnumeration::SetBaseVal;
     virtual uint16_t BaseVal() override { return mVal->GetBaseValue(); }
     virtual void SetBaseVal(uint16_t aBaseVal,
                             mozilla::ErrorResult& aRv) override {
       aRv = mVal->SetBaseValue(aBaseVal, mSVGElement);
     }
     virtual uint16_t AnimVal() override {
       // Script may have modified animation parameters or timeline -- DOM
       // getters need to flush any resample requests to reflect these
--- a/dom/svg/SVGFEBlendElement.cpp
+++ b/dom/svg/SVGFEBlendElement.cpp
@@ -50,25 +50,25 @@ SVGElement::StringInfo SVGFEBlendElement
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEBlendElement)
 
 //----------------------------------------------------------------------
 // nsIDOMSVGFEBlendElement methods
 
-already_AddRefed<SVGAnimatedString> SVGFEBlendElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEBlendElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGFEBlendElement::In2() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEBlendElement::In2() {
   return mStringAttributes[IN2].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGFEBlendElement::Mode() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGFEBlendElement::Mode() {
   return mEnumAttributes[MODE].ToDOMAnimatedEnum(this);
 }
 
 FilterPrimitiveDescription SVGFEBlendElement::GetPrimitiveDescription(
     nsSVGFilterInstance* aInstance, const IntRect& aFilterSubregion,
     const nsTArray<bool>& aInputsAreTainted,
     nsTArray<RefPtr<SourceSurface>>& aInputImages) {
   uint32_t mode = mEnumAttributes[MODE].GetAnimValue();
--- a/dom/svg/SVGFEBlendElement.h
+++ b/dom/svg/SVGFEBlendElement.h
@@ -39,19 +39,19 @@ class SVGFEBlendElement : public SVGFEBl
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedString> In2();
-  already_AddRefed<SVGAnimatedEnumeration> Mode();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedString> In2();
+  already_AddRefed<DOMSVGAnimatedEnumeration> Mode();
 
  protected:
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { MODE };
   SVGEnum mEnumAttributes[1];
   static SVGEnumMapping sModeMap[];
--- a/dom/svg/SVGFEColorMatrixElement.cpp
+++ b/dom/svg/SVGFEColorMatrixElement.cpp
@@ -43,21 +43,21 @@ SVGElement::NumberListInfo SVGFEColorMat
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEColorMatrixElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedString> SVGFEColorMatrixElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEColorMatrixElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGFEColorMatrixElement::Type() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGFEColorMatrixElement::Type() {
   return mEnumAttributes[TYPE].ToDOMAnimatedEnum(this);
 }
 
 already_AddRefed<DOMSVGAnimatedNumberList> SVGFEColorMatrixElement::Values() {
   return DOMSVGAnimatedNumberList::GetDOMWrapper(&mNumberListAttributes[VALUES],
                                                  this, VALUES);
 }
 
--- a/dom/svg/SVGFEColorMatrixElement.h
+++ b/dom/svg/SVGFEColorMatrixElement.h
@@ -43,18 +43,18 @@ class SVGFEColorMatrixElement : public S
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedEnumeration> Type();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedEnumeration> Type();
   already_AddRefed<DOMSVGAnimatedNumberList> Values();
 
  protected:
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
   virtual NumberListAttributesInfo GetNumberListInfo() override;
 
   enum { TYPE };
--- a/dom/svg/SVGFEComponentTransferElement.cpp
+++ b/dom/svg/SVGFEComponentTransferElement.cpp
@@ -28,17 +28,17 @@ SVGElement::StringInfo SVGFEComponentTra
     {nsGkAtoms::result, kNameSpaceID_None, true},
     {nsGkAtoms::in, kNameSpaceID_None, true}};
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEComponentTransferElement)
 
-already_AddRefed<SVGAnimatedString> SVGFEComponentTransferElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEComponentTransferElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 SVGElement::StringAttributesInfo
 SVGFEComponentTransferElement::GetStringInfo() {
--- a/dom/svg/SVGFEComponentTransferElement.h
+++ b/dom/svg/SVGFEComponentTransferElement.h
@@ -40,17 +40,17 @@ class SVGFEComponentTransferElement : pu
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   // nsIContent
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedString> In1();
 
  protected:
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { RESULT, IN1 };
   SVGString mStringAttributes[2];
   static StringInfo sStringInfo[2];
 };
--- a/dom/svg/SVGFECompositeElement.cpp
+++ b/dom/svg/SVGFECompositeElement.cpp
@@ -42,41 +42,41 @@ SVGElement::StringInfo SVGFECompositeEle
     {nsGkAtoms::in, kNameSpaceID_None, true},
     {nsGkAtoms::in2, kNameSpaceID_None, true}};
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFECompositeElement)
 
-already_AddRefed<SVGAnimatedString> SVGFECompositeElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFECompositeElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGFECompositeElement::In2() {
+already_AddRefed<DOMSVGAnimatedString> SVGFECompositeElement::In2() {
   return mStringAttributes[IN2].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGFECompositeElement::Operator() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGFECompositeElement::Operator() {
   return mEnumAttributes[OPERATOR].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFECompositeElement::K1() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFECompositeElement::K1() {
   return mNumberAttributes[ATTR_K1].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFECompositeElement::K2() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFECompositeElement::K2() {
   return mNumberAttributes[ATTR_K2].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFECompositeElement::K3() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFECompositeElement::K3() {
   return mNumberAttributes[ATTR_K3].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFECompositeElement::K4() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFECompositeElement::K4() {
   return mNumberAttributes[ATTR_K4].ToDOMAnimatedNumber(this);
 }
 
 void SVGFECompositeElement::SetK(float k1, float k2, float k3, float k4) {
   mNumberAttributes[ATTR_K1].SetBaseValue(k1, this);
   mNumberAttributes[ATTR_K2].SetBaseValue(k2, this);
   mNumberAttributes[ATTR_K3].SetBaseValue(k3, this);
   mNumberAttributes[ATTR_K4].SetBaseValue(k4, this);
--- a/dom/svg/SVGFECompositeElement.h
+++ b/dom/svg/SVGFECompositeElement.h
@@ -41,23 +41,23 @@ class SVGFECompositeElement : public SVG
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedString> In2();
-  already_AddRefed<SVGAnimatedEnumeration> Operator();
-  already_AddRefed<SVGAnimatedNumber> K1();
-  already_AddRefed<SVGAnimatedNumber> K2();
-  already_AddRefed<SVGAnimatedNumber> K3();
-  already_AddRefed<SVGAnimatedNumber> K4();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedString> In2();
+  already_AddRefed<DOMSVGAnimatedEnumeration> Operator();
+  already_AddRefed<DOMSVGAnimatedNumber> K1();
+  already_AddRefed<DOMSVGAnimatedNumber> K2();
+  already_AddRefed<DOMSVGAnimatedNumber> K3();
+  already_AddRefed<DOMSVGAnimatedNumber> K4();
   void SetK(float k1, float k2, float k3, float k4);
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { ATTR_K1, ATTR_K2, ATTR_K3, ATTR_K4 };
--- a/dom/svg/SVGFEConvolveMatrixElement.cpp
+++ b/dom/svg/SVGFEConvolveMatrixElement.cpp
@@ -57,69 +57,69 @@ SVGElement::NumberListInfo SVGFEConvolve
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEConvolveMatrixElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedString> SVGFEConvolveMatrixElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEConvolveMatrixElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedInteger> SVGFEConvolveMatrixElement::OrderX() {
+already_AddRefed<DOMSVGAnimatedInteger> SVGFEConvolveMatrixElement::OrderX() {
   return mIntegerPairAttributes[ORDER].ToDOMAnimatedInteger(
       SVGIntegerPair::eFirst, this);
 }
 
-already_AddRefed<SVGAnimatedInteger> SVGFEConvolveMatrixElement::OrderY() {
+already_AddRefed<DOMSVGAnimatedInteger> SVGFEConvolveMatrixElement::OrderY() {
   return mIntegerPairAttributes[ORDER].ToDOMAnimatedInteger(
       SVGIntegerPair::eSecond, this);
 }
 
 already_AddRefed<DOMSVGAnimatedNumberList>
 SVGFEConvolveMatrixElement::KernelMatrix() {
   return DOMSVGAnimatedNumberList::GetDOMWrapper(
       &mNumberListAttributes[KERNELMATRIX], this, KERNELMATRIX);
 }
 
-already_AddRefed<SVGAnimatedInteger> SVGFEConvolveMatrixElement::TargetX() {
+already_AddRefed<DOMSVGAnimatedInteger> SVGFEConvolveMatrixElement::TargetX() {
   return mIntegerAttributes[TARGET_X].ToDOMAnimatedInteger(this);
 }
 
-already_AddRefed<SVGAnimatedInteger> SVGFEConvolveMatrixElement::TargetY() {
+already_AddRefed<DOMSVGAnimatedInteger> SVGFEConvolveMatrixElement::TargetY() {
   return mIntegerAttributes[TARGET_Y].ToDOMAnimatedInteger(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration>
+already_AddRefed<DOMSVGAnimatedEnumeration>
 SVGFEConvolveMatrixElement::EdgeMode() {
   return mEnumAttributes[EDGEMODE].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedBoolean>
+already_AddRefed<DOMSVGAnimatedBoolean>
 SVGFEConvolveMatrixElement::PreserveAlpha() {
   return mBooleanAttributes[PRESERVEALPHA].ToDOMAnimatedBoolean(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEConvolveMatrixElement::Divisor() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEConvolveMatrixElement::Divisor() {
   return mNumberAttributes[DIVISOR].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEConvolveMatrixElement::Bias() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEConvolveMatrixElement::Bias() {
   return mNumberAttributes[BIAS].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFEConvolveMatrixElement::KernelUnitLengthX() {
   return mNumberPairAttributes[KERNEL_UNIT_LENGTH].ToDOMAnimatedNumber(
       SVGNumberPair::eFirst, this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFEConvolveMatrixElement::KernelUnitLengthY() {
   return mNumberPairAttributes[KERNEL_UNIT_LENGTH].ToDOMAnimatedNumber(
       SVGNumberPair::eSecond, this);
 }
 
 void SVGFEConvolveMatrixElement::GetSourceImageNames(
     nsTArray<SVGStringInfo>& aSources) {
   aSources.AppendElement(SVGStringInfo(&mStringAttributes[IN1], this));
--- a/dom/svg/SVGFEConvolveMatrixElement.h
+++ b/dom/svg/SVGFEConvolveMatrixElement.h
@@ -2,33 +2,33 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef mozilla_dom_SVGFEConvolveMatrixElement_h
 #define mozilla_dom_SVGFEConvolveMatrixElement_h
 
-#include "SVGAnimatedNumberList.h"
+#include "DOMSVGAnimatedNumberList.h"
 #include "SVGBoolean.h"
 #include "SVGEnum.h"
 #include "SVGFilters.h"
 #include "SVGInteger.h"
 #include "SVGIntegerPair.h"
 #include "nsSVGNumber2.h"
 #include "SVGString.h"
 
 nsresult NS_NewSVGFEConvolveMatrixElement(
     nsIContent** aResult, already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
 namespace mozilla {
 
 namespace dom {
 class DOMSVGAnimatedNumberList;
-class SVGAnimatedBoolean;
+class DOMSVGAnimatedBoolean;
 
 typedef SVGFE SVGFEConvolveMatrixElementBase;
 
 class SVGFEConvolveMatrixElement : public SVGFEConvolveMatrixElementBase {
   friend nsresult(::NS_NewSVGFEConvolveMatrixElement(
       nsIContent** aResult,
       already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo));
 
@@ -49,28 +49,28 @@ class SVGFEConvolveMatrixElement : publi
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedInteger> OrderX();
-  already_AddRefed<SVGAnimatedInteger> OrderY();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedInteger> OrderX();
+  already_AddRefed<DOMSVGAnimatedInteger> OrderY();
   already_AddRefed<DOMSVGAnimatedNumberList> KernelMatrix();
-  already_AddRefed<SVGAnimatedInteger> TargetX();
-  already_AddRefed<SVGAnimatedInteger> TargetY();
-  already_AddRefed<SVGAnimatedEnumeration> EdgeMode();
-  already_AddRefed<SVGAnimatedBoolean> PreserveAlpha();
-  already_AddRefed<SVGAnimatedNumber> Divisor();
-  already_AddRefed<SVGAnimatedNumber> Bias();
-  already_AddRefed<SVGAnimatedNumber> KernelUnitLengthX();
-  already_AddRefed<SVGAnimatedNumber> KernelUnitLengthY();
+  already_AddRefed<DOMSVGAnimatedInteger> TargetX();
+  already_AddRefed<DOMSVGAnimatedInteger> TargetY();
+  already_AddRefed<DOMSVGAnimatedEnumeration> EdgeMode();
+  already_AddRefed<DOMSVGAnimatedBoolean> PreserveAlpha();
+  already_AddRefed<DOMSVGAnimatedNumber> Divisor();
+  already_AddRefed<DOMSVGAnimatedNumber> Bias();
+  already_AddRefed<DOMSVGAnimatedNumber> KernelUnitLengthX();
+  already_AddRefed<DOMSVGAnimatedNumber> KernelUnitLengthY();
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
   virtual NumberPairAttributesInfo GetNumberPairInfo() override;
   virtual IntegerAttributesInfo GetIntegerInfo() override;
   virtual IntegerPairAttributesInfo GetIntegerPairInfo() override;
   virtual BooleanAttributesInfo GetBooleanInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
--- a/dom/svg/SVGFEDiffuseLightingElement.cpp
+++ b/dom/svg/SVGFEDiffuseLightingElement.cpp
@@ -23,37 +23,37 @@ JSObject* SVGFEDiffuseLightingElement::W
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEDiffuseLightingElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedString> SVGFEDiffuseLightingElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEDiffuseLightingElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFEDiffuseLightingElement::SurfaceScale() {
   return mNumberAttributes[SURFACE_SCALE].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFEDiffuseLightingElement::DiffuseConstant() {
   return mNumberAttributes[DIFFUSE_CONSTANT].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFEDiffuseLightingElement::KernelUnitLengthX() {
   return mNumberPairAttributes[KERNEL_UNIT_LENGTH].ToDOMAnimatedNumber(
       SVGNumberPair::eFirst, this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFEDiffuseLightingElement::KernelUnitLengthY() {
   return mNumberPairAttributes[KERNEL_UNIT_LENGTH].ToDOMAnimatedNumber(
       SVGNumberPair::eSecond, this);
 }
 
 FilterPrimitiveDescription SVGFEDiffuseLightingElement::GetPrimitiveDescription(
     nsSVGFilterInstance* aInstance, const IntRect& aFilterSubregion,
     const nsTArray<bool>& aInputsAreTainted,
--- a/dom/svg/SVGFEDiffuseLightingElement.h
+++ b/dom/svg/SVGFEDiffuseLightingElement.h
@@ -35,19 +35,19 @@ class SVGFEDiffuseLightingElement : publ
       const nsTArray<bool>& aInputsAreTainted,
       nsTArray<RefPtr<SourceSurface>>& aInputImages) override;
   virtual bool AttributeAffectsRendering(int32_t aNameSpaceID,
                                          nsAtom* aAttribute) const override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedNumber> SurfaceScale();
-  already_AddRefed<SVGAnimatedNumber> DiffuseConstant();
-  already_AddRefed<SVGAnimatedNumber> KernelUnitLengthX();
-  already_AddRefed<SVGAnimatedNumber> KernelUnitLengthY();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedNumber> SurfaceScale();
+  already_AddRefed<DOMSVGAnimatedNumber> DiffuseConstant();
+  already_AddRefed<DOMSVGAnimatedNumber> KernelUnitLengthX();
+  already_AddRefed<DOMSVGAnimatedNumber> KernelUnitLengthY();
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
 #endif  // mozilla_dom_SVGFEDiffuseLightingElement_h
--- a/dom/svg/SVGFEDisplacementMapElement.cpp
+++ b/dom/svg/SVGFEDisplacementMapElement.cpp
@@ -43,34 +43,34 @@ SVGElement::StringInfo SVGFEDisplacement
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEDisplacementMapElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedString> SVGFEDisplacementMapElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEDisplacementMapElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGFEDisplacementMapElement::In2() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEDisplacementMapElement::In2() {
   return mStringAttributes[IN2].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEDisplacementMapElement::Scale() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEDisplacementMapElement::Scale() {
   return mNumberAttributes[SCALE].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration>
+already_AddRefed<DOMSVGAnimatedEnumeration>
 SVGFEDisplacementMapElement::XChannelSelector() {
   return mEnumAttributes[CHANNEL_X].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration>
+already_AddRefed<DOMSVGAnimatedEnumeration>
 SVGFEDisplacementMapElement::YChannelSelector() {
   return mEnumAttributes[CHANNEL_Y].ToDOMAnimatedEnum(this);
 }
 
 FilterPrimitiveDescription SVGFEDisplacementMapElement::GetPrimitiveDescription(
     nsSVGFilterInstance* aInstance, const IntRect& aFilterSubregion,
     const nsTArray<bool>& aInputsAreTainted,
     nsTArray<RefPtr<SourceSurface>>& aInputImages) {
--- a/dom/svg/SVGFEDisplacementMapElement.h
+++ b/dom/svg/SVGFEDisplacementMapElement.h
@@ -39,21 +39,21 @@ class SVGFEDisplacementMapElement : publ
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedString> In2();
-  already_AddRefed<SVGAnimatedNumber> Scale();
-  already_AddRefed<SVGAnimatedEnumeration> XChannelSelector();
-  already_AddRefed<SVGAnimatedEnumeration> YChannelSelector();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedString> In2();
+  already_AddRefed<DOMSVGAnimatedNumber> Scale();
+  already_AddRefed<DOMSVGAnimatedEnumeration> XChannelSelector();
+  already_AddRefed<DOMSVGAnimatedEnumeration> YChannelSelector();
 
  protected:
   virtual bool OperatesOnSRGB(int32_t aInputIndex,
                               bool aInputIsAlreadySRGB) override {
     switch (aInputIndex) {
       case 0:
         return aInputIsAlreadySRGB;
       case 1:
--- a/dom/svg/SVGFEDistantLightElement.cpp
+++ b/dom/svg/SVGFEDistantLightElement.cpp
@@ -44,21 +44,21 @@ LightType SVGFEDistantLightElement::Comp
   GetAnimatedNumberValues(&azimuth, &elevation, nullptr);
 
   aFloatAttributes.SetLength(kDistantLightNumAttributes);
   aFloatAttributes[kDistantLightAzimuthIndex] = azimuth;
   aFloatAttributes[kDistantLightElevationIndex] = elevation;
   return LightType::Distant;
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEDistantLightElement::Azimuth() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEDistantLightElement::Azimuth() {
   return mNumberAttributes[AZIMUTH].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEDistantLightElement::Elevation() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEDistantLightElement::Elevation() {
   return mNumberAttributes[ELEVATION].ToDOMAnimatedNumber(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 SVGElement::NumberAttributesInfo SVGFEDistantLightElement::GetNumberInfo() {
   return NumberAttributesInfo(mNumberAttributes, sNumberInfo,
--- a/dom/svg/SVGFEDistantLightElement.h
+++ b/dom/svg/SVGFEDistantLightElement.h
@@ -35,18 +35,18 @@ class SVGFEDistantLightElement : public 
       nsSVGFilterInstance* aInstance,
       nsTArray<float>& aFloatAttributes) override;
   virtual bool AttributeAffectsRendering(int32_t aNameSpaceID,
                                          nsAtom* aAttribute) const override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedNumber> Azimuth();
-  already_AddRefed<SVGAnimatedNumber> Elevation();
+  already_AddRefed<DOMSVGAnimatedNumber> Azimuth();
+  already_AddRefed<DOMSVGAnimatedNumber> Elevation();
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
 
   enum { AZIMUTH, ELEVATION };
   nsSVGNumber2 mNumberAttributes[2];
   static NumberInfo sNumberInfo[2];
 };
--- a/dom/svg/SVGFEDropShadowElement.cpp
+++ b/dom/svg/SVGFEDropShadowElement.cpp
@@ -33,34 +33,34 @@ SVGElement::StringInfo SVGFEDropShadowEl
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEDropShadowElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedString> SVGFEDropShadowElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEDropShadowElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEDropShadowElement::Dx() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEDropShadowElement::Dx() {
   return mNumberAttributes[DX].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEDropShadowElement::Dy() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEDropShadowElement::Dy() {
   return mNumberAttributes[DY].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEDropShadowElement::StdDeviationX() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEDropShadowElement::StdDeviationX() {
   return mNumberPairAttributes[STD_DEV].ToDOMAnimatedNumber(
       SVGNumberPair::eFirst, this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEDropShadowElement::StdDeviationY() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEDropShadowElement::StdDeviationY() {
   return mNumberPairAttributes[STD_DEV].ToDOMAnimatedNumber(
       SVGNumberPair::eSecond, this);
 }
 
 void SVGFEDropShadowElement::SetStdDeviation(float stdDeviationX,
                                              float stdDeviationY) {
   mNumberPairAttributes[STD_DEV].SetBaseValues(stdDeviationX, stdDeviationY,
                                                this);
--- a/dom/svg/SVGFEDropShadowElement.h
+++ b/dom/svg/SVGFEDropShadowElement.h
@@ -45,21 +45,21 @@ class SVGFEDropShadowElement : public SV
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   // nsIContent interface
   NS_IMETHOD_(bool) IsAttributeMapped(const nsAtom* aAttribute) const override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedNumber> Dx();
-  already_AddRefed<SVGAnimatedNumber> Dy();
-  already_AddRefed<SVGAnimatedNumber> StdDeviationX();
-  already_AddRefed<SVGAnimatedNumber> StdDeviationY();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedNumber> Dx();
+  already_AddRefed<DOMSVGAnimatedNumber> Dy();
+  already_AddRefed<DOMSVGAnimatedNumber> StdDeviationX();
+  already_AddRefed<DOMSVGAnimatedNumber> StdDeviationY();
   void SetStdDeviation(float stdDeviationX, float stdDeviationY);
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
   virtual NumberPairAttributesInfo GetNumberPairInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { DX, DY };
--- a/dom/svg/SVGFEGaussianBlurElement.cpp
+++ b/dom/svg/SVGFEGaussianBlurElement.cpp
@@ -30,26 +30,28 @@ SVGElement::StringInfo SVGFEGaussianBlur
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEGaussianBlurElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedString> SVGFEGaussianBlurElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEGaussianBlurElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEGaussianBlurElement::StdDeviationX() {
+already_AddRefed<DOMSVGAnimatedNumber>
+SVGFEGaussianBlurElement::StdDeviationX() {
   return mNumberPairAttributes[STD_DEV].ToDOMAnimatedNumber(
       SVGNumberPair::eFirst, this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEGaussianBlurElement::StdDeviationY() {
+already_AddRefed<DOMSVGAnimatedNumber>
+SVGFEGaussianBlurElement::StdDeviationY() {
   return mNumberPairAttributes[STD_DEV].ToDOMAnimatedNumber(
       SVGNumberPair::eSecond, this);
 }
 
 void SVGFEGaussianBlurElement::SetStdDeviation(float stdDeviationX,
                                                float stdDeviationY) {
   mNumberPairAttributes[STD_DEV].SetBaseValues(stdDeviationX, stdDeviationY,
                                                this);
--- a/dom/svg/SVGFEGaussianBlurElement.h
+++ b/dom/svg/SVGFEGaussianBlurElement.h
@@ -41,19 +41,19 @@ class SVGFEGaussianBlurElement : public 
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedNumber> StdDeviationX();
-  already_AddRefed<SVGAnimatedNumber> StdDeviationY();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedNumber> StdDeviationX();
+  already_AddRefed<DOMSVGAnimatedNumber> StdDeviationY();
   void SetStdDeviation(float stdDeviationX, float stdDeviationY);
 
  protected:
   virtual NumberPairAttributesInfo GetNumberPairInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { STD_DEV };
   SVGNumberPair mNumberPairAttributes[1];
--- a/dom/svg/SVGFEImageElement.cpp
+++ b/dom/svg/SVGFEImageElement.cpp
@@ -160,17 +160,17 @@ EventStates SVGFEImageElement::Intrinsic
          nsImageLoadingContent::ImageState();
 }
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEImageElement)
 
-already_AddRefed<SVGAnimatedString> SVGFEImageElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEImageElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // nsIDOMSVGFEImageElement methods
 
--- a/dom/svg/SVGFEImageElement.h
+++ b/dom/svg/SVGFEImageElement.h
@@ -74,17 +74,17 @@ class SVGFEImageElement final : public S
                     const nsIntRect* aData) override;
 
   // Override for nsIImageLoadingContent.
   NS_IMETHOD_(void) FrameCreated(nsIFrame* aFrame) override;
 
   void MaybeLoadSVGImage();
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedString> Href();
   already_AddRefed<DOMSVGAnimatedPreserveAspectRatio> PreserveAspectRatio();
 
  private:
   nsresult LoadSVGImage(bool aForce, bool aNotify);
 
  protected:
   virtual bool ProducesSRGB() override { return true; }
 
--- a/dom/svg/SVGFEMergeNodeElement.cpp
+++ b/dom/svg/SVGFEMergeNodeElement.cpp
@@ -28,17 +28,17 @@ NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEMer
 //----------------------------------------------------------------------
 // nsFEUnstyledElement methods
 
 bool SVGFEMergeNodeElement::AttributeAffectsRendering(
     int32_t aNameSpaceID, nsAtom* aAttribute) const {
   return aNameSpaceID == kNameSpaceID_None && aAttribute == nsGkAtoms::in;
 }
 
-already_AddRefed<SVGAnimatedString> SVGFEMergeNodeElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEMergeNodeElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 SVGElement::StringAttributesInfo SVGFEMergeNodeElement::GetStringInfo() {
   return StringAttributesInfo(mStringAttributes, sStringInfo,
--- a/dom/svg/SVGFEMergeNodeElement.h
+++ b/dom/svg/SVGFEMergeNodeElement.h
@@ -33,17 +33,17 @@ class SVGFEMergeNodeElement : public SVG
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   virtual bool AttributeAffectsRendering(int32_t aNameSpaceID,
                                          nsAtom* aAttribute) const override;
 
   const SVGString* GetIn1() { return &mStringAttributes[IN1]; }
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedString> In1();
 
  protected:
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { IN1 };
   SVGString mStringAttributes[1];
   static StringInfo sStringInfo[1];
 };
--- a/dom/svg/SVGFEMorphologyElement.cpp
+++ b/dom/svg/SVGFEMorphologyElement.cpp
@@ -38,30 +38,30 @@ SVGElement::StringInfo SVGFEMorphologyEl
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEMorphologyElement)
 
 //----------------------------------------------------------------------
 // SVGFEMorphologyElement methods
 
-already_AddRefed<SVGAnimatedString> SVGFEMorphologyElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEMorphologyElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGFEMorphologyElement::Operator() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGFEMorphologyElement::Operator() {
   return mEnumAttributes[OPERATOR].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEMorphologyElement::RadiusX() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEMorphologyElement::RadiusX() {
   return mNumberPairAttributes[RADIUS].ToDOMAnimatedNumber(
       SVGNumberPair::eFirst, this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEMorphologyElement::RadiusY() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEMorphologyElement::RadiusY() {
   return mNumberPairAttributes[RADIUS].ToDOMAnimatedNumber(
       SVGNumberPair::eSecond, this);
 }
 
 void SVGFEMorphologyElement::SetRadius(float rx, float ry) {
   mNumberPairAttributes[RADIUS].SetBaseValues(rx, ry, this);
 }
 
--- a/dom/svg/SVGFEMorphologyElement.h
+++ b/dom/svg/SVGFEMorphologyElement.h
@@ -42,20 +42,20 @@ class SVGFEMorphologyElement : public SV
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedEnumeration> Operator();
-  already_AddRefed<SVGAnimatedNumber> RadiusX();
-  already_AddRefed<SVGAnimatedNumber> RadiusY();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedEnumeration> Operator();
+  already_AddRefed<DOMSVGAnimatedNumber> RadiusX();
+  already_AddRefed<DOMSVGAnimatedNumber> RadiusY();
   void SetRadius(float rx, float ry);
 
  protected:
   void GetRXY(int32_t* aRX, int32_t* aRY, const nsSVGFilterInstance& aInstance);
 
   virtual NumberPairAttributesInfo GetNumberPairInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
--- a/dom/svg/SVGFEOffsetElement.cpp
+++ b/dom/svg/SVGFEOffsetElement.cpp
@@ -29,25 +29,25 @@ SVGElement::StringInfo SVGFEOffsetElemen
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEOffsetElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedString> SVGFEOffsetElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFEOffsetElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEOffsetElement::Dx() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEOffsetElement::Dx() {
   return mNumberAttributes[DX].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEOffsetElement::Dy() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEOffsetElement::Dy() {
   return mNumberAttributes[DY].ToDOMAnimatedNumber(this);
 }
 
 FilterPrimitiveDescription SVGFEOffsetElement::GetPrimitiveDescription(
     nsSVGFilterInstance* aInstance, const IntRect& aFilterSubregion,
     const nsTArray<bool>& aInputsAreTainted,
     nsTArray<RefPtr<SourceSurface>>& aInputImages) {
   OffsetAttributes atts;
--- a/dom/svg/SVGFEOffsetElement.h
+++ b/dom/svg/SVGFEOffsetElement.h
@@ -41,19 +41,19 @@ class SVGFEOffsetElement : public SVGFEO
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedNumber> Dx();
-  already_AddRefed<SVGAnimatedNumber> Dy();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedNumber> Dx();
+  already_AddRefed<DOMSVGAnimatedNumber> Dy();
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { DX, DY };
   nsSVGNumber2 mNumberAttributes[2];
   static NumberInfo sNumberInfo[2];
--- a/dom/svg/SVGFEPointLightElement.cpp
+++ b/dom/svg/SVGFEPointLightElement.cpp
@@ -49,25 +49,25 @@ LightType SVGFEPointLightElement::Comput
   lightPos = aInstance->ConvertLocation(lightPos);
   aFloatAttributes.SetLength(kPointLightNumAttributes);
   aFloatAttributes[kPointLightPositionXIndex] = lightPos.x;
   aFloatAttributes[kPointLightPositionYIndex] = lightPos.y;
   aFloatAttributes[kPointLightPositionZIndex] = lightPos.z;
   return LightType::Point;
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEPointLightElement::X() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEPointLightElement::X() {
   return mNumberAttributes[ATTR_X].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEPointLightElement::Y() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEPointLightElement::Y() {
   return mNumberAttributes[ATTR_Y].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFEPointLightElement::Z() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFEPointLightElement::Z() {
   return mNumberAttributes[ATTR_Z].ToDOMAnimatedNumber(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 SVGElement::NumberAttributesInfo SVGFEPointLightElement::GetNumberInfo() {
   return NumberAttributesInfo(mNumberAttributes, sNumberInfo,
--- a/dom/svg/SVGFEPointLightElement.h
+++ b/dom/svg/SVGFEPointLightElement.h
@@ -35,19 +35,19 @@ class SVGFEPointLightElement : public SV
       nsSVGFilterInstance* aInstance,
       nsTArray<float>& aFloatAttributes) override;
   virtual bool AttributeAffectsRendering(int32_t aNameSpaceID,
                                          nsAtom* aAttribute) const override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedNumber> X();
-  already_AddRefed<SVGAnimatedNumber> Y();
-  already_AddRefed<SVGAnimatedNumber> Z();
+  already_AddRefed<DOMSVGAnimatedNumber> X();
+  already_AddRefed<DOMSVGAnimatedNumber> Y();
+  already_AddRefed<DOMSVGAnimatedNumber> Z();
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
 
   enum { ATTR_X, ATTR_Y, ATTR_Z };
   nsSVGNumber2 mNumberAttributes[3];
   static NumberInfo sNumberInfo[3];
 };
--- a/dom/svg/SVGFESpecularLightingElement.cpp
+++ b/dom/svg/SVGFESpecularLightingElement.cpp
@@ -21,42 +21,42 @@ JSObject* SVGFESpecularLightingElement::
   return SVGFESpecularLightingElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFESpecularLightingElement)
 
-already_AddRefed<SVGAnimatedString> SVGFESpecularLightingElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFESpecularLightingElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFESpecularLightingElement::SurfaceScale() {
   return mNumberAttributes[SURFACE_SCALE].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFESpecularLightingElement::SpecularConstant() {
   return mNumberAttributes[SPECULAR_CONSTANT].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFESpecularLightingElement::SpecularExponent() {
   return mNumberAttributes[SPECULAR_EXPONENT].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFESpecularLightingElement::KernelUnitLengthX() {
   return mNumberPairAttributes[KERNEL_UNIT_LENGTH].ToDOMAnimatedNumber(
       SVGNumberPair::eFirst, this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGFESpecularLightingElement::KernelUnitLengthY() {
   return mNumberPairAttributes[KERNEL_UNIT_LENGTH].ToDOMAnimatedNumber(
       SVGNumberPair::eSecond, this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
--- a/dom/svg/SVGFESpecularLightingElement.h
+++ b/dom/svg/SVGFESpecularLightingElement.h
@@ -37,20 +37,20 @@ class SVGFESpecularLightingElement : pub
   virtual FilterPrimitiveDescription GetPrimitiveDescription(
       nsSVGFilterInstance* aInstance, const IntRect& aFilterSubregion,
       const nsTArray<bool>& aInputsAreTainted,
       nsTArray<RefPtr<SourceSurface>>& aInputImages) override;
   virtual bool AttributeAffectsRendering(int32_t aNameSpaceID,
                                          nsAtom* aAttribute) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
-  already_AddRefed<SVGAnimatedNumber> SurfaceScale();
-  already_AddRefed<SVGAnimatedNumber> SpecularConstant();
-  already_AddRefed<SVGAnimatedNumber> SpecularExponent();
-  already_AddRefed<SVGAnimatedNumber> KernelUnitLengthX();
-  already_AddRefed<SVGAnimatedNumber> KernelUnitLengthY();
+  already_AddRefed<DOMSVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedNumber> SurfaceScale();
+  already_AddRefed<DOMSVGAnimatedNumber> SpecularConstant();
+  already_AddRefed<DOMSVGAnimatedNumber> SpecularExponent();
+  already_AddRefed<DOMSVGAnimatedNumber> KernelUnitLengthX();
+  already_AddRefed<DOMSVGAnimatedNumber> KernelUnitLengthY();
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
 #endif  // mozilla_dom_SVGFESpecularLightingElement_h
--- a/dom/svg/SVGFESpotLightElement.cpp
+++ b/dom/svg/SVGFESpotLightElement.cpp
@@ -66,45 +66,47 @@ LightType SVGFESpotLightElement::Compute
   if (!mNumberAttributes[SVGFESpotLightElement::LIMITING_CONE_ANGLE]
            .IsExplicitlySet()) {
     aFloatAttributes[kSpotLightLimitingConeAngleIndex] = 90;
   }
 
   return LightType::Spot;
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFESpotLightElement::X() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFESpotLightElement::X() {
   return mNumberAttributes[ATTR_X].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFESpotLightElement::Y() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFESpotLightElement::Y() {
   return mNumberAttributes[ATTR_Y].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFESpotLightElement::Z() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFESpotLightElement::Z() {
   return mNumberAttributes[ATTR_Z].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFESpotLightElement::PointsAtX() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFESpotLightElement::PointsAtX() {
   return mNumberAttributes[POINTS_AT_X].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFESpotLightElement::PointsAtY() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFESpotLightElement::PointsAtY() {
   return mNumberAttributes[POINTS_AT_Y].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFESpotLightElement::PointsAtZ() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFESpotLightElement::PointsAtZ() {
   return mNumberAttributes[POINTS_AT_Z].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFESpotLightElement::SpecularExponent() {
+already_AddRefed<DOMSVGAnimatedNumber>
+SVGFESpotLightElement::SpecularExponent() {
   return mNumberAttributes[SPECULAR_EXPONENT].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFESpotLightElement::LimitingConeAngle() {
+already_AddRefed<DOMSVGAnimatedNumber>
+SVGFESpotLightElement::LimitingConeAngle() {
   return mNumberAttributes[LIMITING_CONE_ANGLE].ToDOMAnimatedNumber(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 SVGElement::NumberAttributesInfo SVGFESpotLightElement::GetNumberInfo() {
   return NumberAttributesInfo(mNumberAttributes, sNumberInfo,
--- a/dom/svg/SVGFESpotLightElement.h
+++ b/dom/svg/SVGFESpotLightElement.h
@@ -36,24 +36,24 @@ class SVGFESpotLightElement : public SVG
       nsSVGFilterInstance* aInstance,
       nsTArray<float>& aFloatAttributes) override;
   virtual bool AttributeAffectsRendering(int32_t aNameSpaceID,
                                          nsAtom* aAttribute) const override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedNumber> X();
-  already_AddRefed<SVGAnimatedNumber> Y();
-  already_AddRefed<SVGAnimatedNumber> Z();
-  already_AddRefed<SVGAnimatedNumber> PointsAtX();
-  already_AddRefed<SVGAnimatedNumber> PointsAtY();
-  already_AddRefed<SVGAnimatedNumber> PointsAtZ();
-  already_AddRefed<SVGAnimatedNumber> SpecularExponent();
-  already_AddRefed<SVGAnimatedNumber> LimitingConeAngle();
+  already_AddRefed<DOMSVGAnimatedNumber> X();
+  already_AddRefed<DOMSVGAnimatedNumber> Y();
+  already_AddRefed<DOMSVGAnimatedNumber> Z();
+  already_AddRefed<DOMSVGAnimatedNumber> PointsAtX();
+  already_AddRefed<DOMSVGAnimatedNumber> PointsAtY();
+  already_AddRefed<DOMSVGAnimatedNumber> PointsAtZ();
+  already_AddRefed<DOMSVGAnimatedNumber> SpecularExponent();
+  already_AddRefed<DOMSVGAnimatedNumber> LimitingConeAngle();
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
 
   enum {
     ATTR_X,
     ATTR_Y,
     ATTR_Z,
--- a/dom/svg/SVGFETileElement.cpp
+++ b/dom/svg/SVGFETileElement.cpp
@@ -24,17 +24,17 @@ SVGElement::StringInfo SVGFETileElement:
     {nsGkAtoms::result, kNameSpaceID_None, true},
     {nsGkAtoms::in, kNameSpaceID_None, true}};
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFETileElement)
 
-already_AddRefed<SVGAnimatedString> SVGFETileElement::In1() {
+already_AddRefed<DOMSVGAnimatedString> SVGFETileElement::In1() {
   return mStringAttributes[IN1].ToDOMAnimatedString(this);
 }
 
 void SVGFETileElement::GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) {
   aSources.AppendElement(SVGStringInfo(&mStringAttributes[IN1], this));
 }
 
 //----------------------------------------------------------------------
--- a/dom/svg/SVGFETileElement.h
+++ b/dom/svg/SVGFETileElement.h
@@ -41,17 +41,17 @@ class SVGFETileElement : public SVGFETil
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
   virtual void GetSourceImageNames(nsTArray<SVGStringInfo>& aSources) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> In1();
+  already_AddRefed<DOMSVGAnimatedString> In1();
 
  protected:
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { RESULT, IN1 };
   SVGString mStringAttributes[2];
   static StringInfo sStringInfo[2];
 };
--- a/dom/svg/SVGFETurbulenceElement.cpp
+++ b/dom/svg/SVGFETurbulenceElement.cpp
@@ -55,39 +55,42 @@ SVGElement::StringInfo SVGFETurbulenceEl
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFETurbulenceElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedNumber> SVGFETurbulenceElement::BaseFrequencyX() {
+already_AddRefed<DOMSVGAnimatedNumber>
+SVGFETurbulenceElement::BaseFrequencyX() {
   return mNumberPairAttributes[BASE_FREQ].ToDOMAnimatedNumber(
       SVGNumberPair::eFirst, this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFETurbulenceElement::BaseFrequencyY() {
+already_AddRefed<DOMSVGAnimatedNumber>
+SVGFETurbulenceElement::BaseFrequencyY() {
   return mNumberPairAttributes[BASE_FREQ].ToDOMAnimatedNumber(
       SVGNumberPair::eSecond, this);
 }
 
-already_AddRefed<SVGAnimatedInteger> SVGFETurbulenceElement::NumOctaves() {
+already_AddRefed<DOMSVGAnimatedInteger> SVGFETurbulenceElement::NumOctaves() {
   return mIntegerAttributes[OCTAVES].ToDOMAnimatedInteger(this);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGFETurbulenceElement::Seed() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGFETurbulenceElement::Seed() {
   return mNumberAttributes[SEED].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGFETurbulenceElement::StitchTiles() {
+already_AddRefed<DOMSVGAnimatedEnumeration>
+SVGFETurbulenceElement::StitchTiles() {
   return mEnumAttributes[STITCHTILES].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGFETurbulenceElement::Type() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGFETurbulenceElement::Type() {
   return mEnumAttributes[TYPE].ToDOMAnimatedEnum(this);
 }
 
 FilterPrimitiveDescription SVGFETurbulenceElement::GetPrimitiveDescription(
     nsSVGFilterInstance* aInstance, const IntRect& aFilterSubregion,
     const nsTArray<bool>& aInputsAreTainted,
     nsTArray<RefPtr<SourceSurface>>& aInputImages) {
   float fX =
--- a/dom/svg/SVGFETurbulenceElement.h
+++ b/dom/svg/SVGFETurbulenceElement.h
@@ -44,22 +44,22 @@ class SVGFETurbulenceElement : public SV
                                          nsAtom* aAttribute) const override;
   virtual SVGString& GetResultImageName() override {
     return mStringAttributes[RESULT];
   }
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedNumber> BaseFrequencyX();
-  already_AddRefed<SVGAnimatedNumber> BaseFrequencyY();
-  already_AddRefed<SVGAnimatedInteger> NumOctaves();
-  already_AddRefed<SVGAnimatedNumber> Seed();
-  already_AddRefed<SVGAnimatedEnumeration> StitchTiles();
-  already_AddRefed<SVGAnimatedEnumeration> Type();
+  already_AddRefed<DOMSVGAnimatedNumber> BaseFrequencyX();
+  already_AddRefed<DOMSVGAnimatedNumber> BaseFrequencyY();
+  already_AddRefed<DOMSVGAnimatedInteger> NumOctaves();
+  already_AddRefed<DOMSVGAnimatedNumber> Seed();
+  already_AddRefed<DOMSVGAnimatedEnumeration> StitchTiles();
+  already_AddRefed<DOMSVGAnimatedEnumeration> Type();
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
   virtual NumberPairAttributesInfo GetNumberPairInfo() override;
   virtual IntegerAttributesInfo GetIntegerInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
--- a/dom/svg/SVGFilterElement.cpp
+++ b/dom/svg/SVGFilterElement.cpp
@@ -57,41 +57,41 @@ SVGFilterElement::SVGFilterElement(
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFilterElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGFilterElement::X() {
+already_AddRefed<DOMSVGAnimatedLength> SVGFilterElement::X() {
   return mLengthAttributes[ATTR_X].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGFilterElement::Y() {
+already_AddRefed<DOMSVGAnimatedLength> SVGFilterElement::Y() {
   return mLengthAttributes[ATTR_Y].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGFilterElement::Width() {
+already_AddRefed<DOMSVGAnimatedLength> SVGFilterElement::Width() {
   return mLengthAttributes[ATTR_WIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGFilterElement::Height() {
+already_AddRefed<DOMSVGAnimatedLength> SVGFilterElement::Height() {
   return mLengthAttributes[ATTR_HEIGHT].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGFilterElement::FilterUnits() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGFilterElement::FilterUnits() {
   return mEnumAttributes[FILTERUNITS].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGFilterElement::PrimitiveUnits() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGFilterElement::PrimitiveUnits() {
   return mEnumAttributes[PRIMITIVEUNITS].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGFilterElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGFilterElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // nsIContent methods
 
--- a/dom/svg/SVGFilterElement.h
+++ b/dom/svg/SVGFilterElement.h
@@ -15,17 +15,17 @@
 class nsSVGFilterFrame;
 class nsSVGFilterInstance;
 
 nsresult NS_NewSVGFilterElement(
     nsIContent** aResult, already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
 namespace mozilla {
 namespace dom {
-class SVGAnimatedLength;
+class DOMSVGAnimatedLength;
 
 typedef SVGElement SVGFilterElementBase;
 
 class SVGFilterElement : public SVGFilterElementBase {
   friend class ::nsSVGFilterFrame;
   friend class ::nsSVGFilterInstance;
 
  protected:
@@ -41,23 +41,23 @@ class SVGFilterElement : public SVGFilte
   // nsIContent
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
   NS_IMETHOD_(bool) IsAttributeMapped(const nsAtom* aAttribute) const override;
 
   // nsSVGSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> X();
-  already_AddRefed<SVGAnimatedLength> Y();
-  already_AddRefed<SVGAnimatedLength> Width();
-  already_AddRefed<SVGAnimatedLength> Height();
-  already_AddRefed<SVGAnimatedEnumeration> FilterUnits();
-  already_AddRefed<SVGAnimatedEnumeration> PrimitiveUnits();
-  already_AddRefed<SVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedLength> X();
+  already_AddRefed<DOMSVGAnimatedLength> Y();
+  already_AddRefed<DOMSVGAnimatedLength> Width();
+  already_AddRefed<DOMSVGAnimatedLength> Height();
+  already_AddRefed<DOMSVGAnimatedEnumeration> FilterUnits();
+  already_AddRefed<DOMSVGAnimatedEnumeration> PrimitiveUnits();
+  already_AddRefed<DOMSVGAnimatedString> Href();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { ATTR_X, ATTR_Y, ATTR_WIDTH, ATTR_HEIGHT };
   nsSVGLength2 mLengthAttributes[4];
--- a/dom/svg/SVGFilters.cpp
+++ b/dom/svg/SVGFilters.cpp
@@ -3,32 +3,31 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #include "SVGFilters.h"
 
 #include <algorithm>
 #include "DOMSVGAnimatedNumberList.h"
+#include "DOMSVGAnimatedLength.h"
 #include "imgIContainer.h"
 #include "nsGkAtoms.h"
 #include "nsCOMPtr.h"
 #include "nsIFrame.h"
 #include "nsLayoutUtils.h"
-#include "SVGAnimatedNumberList.h"
 #include "SVGEnum.h"
 #include "nsSVGFilterInstance.h"
 #include "SVGNumberList.h"
 #include "SVGNumberPair.h"
 #include "SVGString.h"
 #include "mozilla/ArrayUtils.h"
 #include "mozilla/ComputedStyle.h"
 #include "mozilla/SVGContentUtils.h"
 #include "nsSVGUtils.h"
-#include "mozilla/dom/SVGAnimatedLength.h"
 #include "mozilla/dom/SVGComponentTransferFunctionElement.h"
 #include "mozilla/dom/SVGElement.h"
 #include "mozilla/dom/SVGFEDistantLightElement.h"
 #include "mozilla/dom/SVGFEFuncAElementBinding.h"
 #include "mozilla/dom/SVGFEFuncBElementBinding.h"
 #include "mozilla/dom/SVGFEFuncGElementBinding.h"
 #include "mozilla/dom/SVGFEFuncRElementBinding.h"
 #include "mozilla/dom/SVGFEPointLightElement.h"
@@ -88,33 +87,33 @@ bool SVGFE::OutputIsTainted(const nsTArr
 bool SVGFE::AttributeAffectsRendering(int32_t aNameSpaceID,
                                       nsAtom* aAttribute) const {
   return aNameSpaceID == kNameSpaceID_None &&
          (aAttribute == nsGkAtoms::x || aAttribute == nsGkAtoms::y ||
           aAttribute == nsGkAtoms::width || aAttribute == nsGkAtoms::height ||
           aAttribute == nsGkAtoms::result);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGFE::X() {
+already_AddRefed<DOMSVGAnimatedLength> SVGFE::X() {
   return mLengthAttributes[ATTR_X].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGFE::Y() {
+already_AddRefed<DOMSVGAnimatedLength> SVGFE::Y() {
   return mLengthAttributes[ATTR_Y].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGFE::Width() {
+already_AddRefed<DOMSVGAnimatedLength> SVGFE::Width() {
   return mLengthAttributes[ATTR_WIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGFE::Height() {
+already_AddRefed<DOMSVGAnimatedLength> SVGFE::Height() {
   return mLengthAttributes[ATTR_HEIGHT].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGFE::Result() {
+already_AddRefed<DOMSVGAnimatedString> SVGFE::Result() {
   return GetResultImageName().ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // nsIContent methods
 
 NS_IMETHODIMP_(bool)
 SVGFE::IsAttributeMapped(const nsAtom* name) const {
@@ -207,48 +206,48 @@ bool SVGComponentTransferFunctionElement
           aAttribute == nsGkAtoms::intercept ||
           aAttribute == nsGkAtoms::amplitude ||
           aAttribute == nsGkAtoms::exponent ||
           aAttribute == nsGkAtoms::offset || aAttribute == nsGkAtoms::type);
 }
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedEnumeration>
+already_AddRefed<DOMSVGAnimatedEnumeration>
 SVGComponentTransferFunctionElement::Type() {
   return mEnumAttributes[TYPE].ToDOMAnimatedEnum(this);
 }
 
 already_AddRefed<DOMSVGAnimatedNumberList>
 SVGComponentTransferFunctionElement::TableValues() {
   return DOMSVGAnimatedNumberList::GetDOMWrapper(
       &mNumberListAttributes[TABLEVALUES], this, TABLEVALUES);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGComponentTransferFunctionElement::Slope() {
   return mNumberAttributes[SLOPE].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGComponentTransferFunctionElement::Intercept() {
   return mNumberAttributes[INTERCEPT].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGComponentTransferFunctionElement::Amplitude() {
   return mNumberAttributes[AMPLITUDE].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGComponentTransferFunctionElement::Exponent() {
   return mNumberAttributes[EXPONENT].ToDOMAnimatedNumber(this);
 }
 
-already_AddRefed<SVGAnimatedNumber>
+already_AddRefed<DOMSVGAnimatedNumber>
 SVGComponentTransferFunctionElement::Offset() {
   return mNumberAttributes[OFFSET].ToDOMAnimatedNumber(this);
 }
 
 void SVGComponentTransferFunctionElement::ComputeAttributes(
     int32_t aChannel, ComponentTransferAttributes& aAttributes) {
   uint32_t type = mEnumAttributes[TYPE].GetAnimValue();
 
--- a/dom/svg/SVGFilters.h
+++ b/dom/svg/SVGFilters.h
@@ -121,21 +121,21 @@ class SVGFE : public SVGFEBase {
     // Try to avoid overflow errors dealing with this rect. It will
     // be intersected with some other reasonable-sized rect eventually.
     return nsIntRect(INT32_MIN / 2, INT32_MIN / 2, INT32_MAX, INT32_MAX);
   }
 
   operator nsISupports*() { return static_cast<nsIContent*>(this); }
 
   // WebIDL
-  already_AddRefed<mozilla::dom::SVGAnimatedLength> X();
-  already_AddRefed<mozilla::dom::SVGAnimatedLength> Y();
-  already_AddRefed<mozilla::dom::SVGAnimatedLength> Width();
-  already_AddRefed<mozilla::dom::SVGAnimatedLength> Height();
-  already_AddRefed<mozilla::dom::SVGAnimatedString> Result();
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedLength> X();
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedLength> Y();
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedLength> Width();
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedLength> Height();
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedString> Result();
 
  protected:
   virtual bool OperatesOnSRGB(int32_t aInputIndex, bool aInputIsAlreadySRGB) {
     return StyleIsSetToSRGB();
   }
 
   // Only called for filter primitives without inputs.
   virtual bool ProducesSRGB() { return StyleIsSetToSRGB(); }
--- a/dom/svg/SVGForeignObjectElement.cpp
+++ b/dom/svg/SVGForeignObjectElement.cpp
@@ -42,29 +42,29 @@ SVGForeignObjectElement::SVGForeignObjec
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGForeignObjectElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGForeignObjectElement::X() {
+already_AddRefed<DOMSVGAnimatedLength> SVGForeignObjectElement::X() {
   return mLengthAttributes[ATTR_X].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGForeignObjectElement::Y() {
+already_AddRefed<DOMSVGAnimatedLength> SVGForeignObjectElement::Y() {
   return mLengthAttributes[ATTR_Y].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGForeignObjectElement::Width() {
+already_AddRefed<DOMSVGAnimatedLength> SVGForeignObjectElement::Width() {
   return mLengthAttributes[ATTR_WIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGForeignObjectElement::Height() {
+already_AddRefed<DOMSVGAnimatedLength> SVGForeignObjectElement::Height() {
   return mLengthAttributes[ATTR_HEIGHT].ToDOMAnimatedLength(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 /* virtual */
 gfxMatrix SVGForeignObjectElement::PrependLocalTransformsTo(
--- a/dom/svg/SVGForeignObjectElement.h
+++ b/dom/svg/SVGForeignObjectElement.h
@@ -38,20 +38,20 @@ class SVGForeignObjectElement final : pu
   virtual bool HasValidDimensions() const override;
 
   // nsIContent interface
   NS_IMETHOD_(bool) IsAttributeMapped(const nsAtom* name) const override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> X();
-  already_AddRefed<SVGAnimatedLength> Y();
-  already_AddRefed<SVGAnimatedLength> Width();
-  already_AddRefed<SVGAnimatedLength> Height();
+  already_AddRefed<DOMSVGAnimatedLength> X();
+  already_AddRefed<DOMSVGAnimatedLength> Y();
+  already_AddRefed<DOMSVGAnimatedLength> Width();
+  already_AddRefed<DOMSVGAnimatedLength> Height();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
 
   enum { ATTR_X, ATTR_Y, ATTR_WIDTH, ATTR_HEIGHT };
   nsSVGLength2 mLengthAttributes[4];
   static LengthInfo sLengthInfo[4];
 };
--- a/dom/svg/SVGGeometryElement.cpp
+++ b/dom/svg/SVGGeometryElement.cpp
@@ -174,11 +174,11 @@ float SVGGeometryElement::GetPathLengthS
         }
       }
       return path->ComputeLength() / authorsPathLengthEstimate;
     }
   }
   return 1.0;
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGGeometryElement::PathLength() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGGeometryElement::PathLength() {
   return mPathLength.ToDOMAnimatedNumber(this);
 }
--- a/dom/svg/SVGGeometryElement.h
+++ b/dom/svg/SVGGeometryElement.h
@@ -26,17 +26,17 @@ struct SVGMark {
   float x, y, angle;
   Type type;
   SVGMark(float aX, float aY, float aAngle, Type aType)
       : x(aX), y(aY), angle(aAngle), type(aType) {}
 };
 
 namespace dom {
 
-class SVGAnimatedNumber;
+class DOMSVGAnimatedNumber;
 
 typedef mozilla::dom::SVGGraphicsElement SVGGeometryElementBase;
 
 class SVGGeometryElement : public SVGGeometryElementBase {
  protected:
   typedef mozilla::gfx::CapStyle CapStyle;
   typedef mozilla::gfx::DrawTarget DrawTarget;
   typedef mozilla::gfx::FillRule FillRule;
@@ -203,17 +203,17 @@ class SVGGeometryElement : public SVGGeo
    * Gets the ratio of the actual element's length to the content author's
    * estimated length (as provided by the element's 'pathLength' attribute).
    * This is used to scale stroke dashing, and to scale offsets along a
    * textPath.
    */
   float GetPathLengthScale(PathLengthScaleForType aFor);
 
   // WebIDL
-  already_AddRefed<SVGAnimatedNumber> PathLength();
+  already_AddRefed<DOMSVGAnimatedNumber> PathLength();
   float GetTotalLength();
   already_AddRefed<nsISVGPoint> GetPointAtLength(float distance,
                                                  ErrorResult& rv);
 
  protected:
   // SVGElement method
   virtual NumberAttributesInfo GetNumberInfo() override;
 
--- a/dom/svg/SVGGradientElement.cpp
+++ b/dom/svg/SVGGradientElement.cpp
@@ -57,33 +57,34 @@ SVGElement::EnumAttributesInfo SVGGradie
   return EnumAttributesInfo(mEnumAttributes, sEnumInfo, ArrayLength(sEnumInfo));
 }
 
 SVGElement::StringAttributesInfo SVGGradientElement::GetStringInfo() {
   return StringAttributesInfo(mStringAttributes, sStringInfo,
                               ArrayLength(sStringInfo));
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGGradientElement::GradientUnits() {
+already_AddRefed<DOMSVGAnimatedEnumeration>
+SVGGradientElement::GradientUnits() {
   return mEnumAttributes[GRADIENTUNITS].ToDOMAnimatedEnum(this);
 }
 
 already_AddRefed<DOMSVGAnimatedTransformList>
 SVGGradientElement::GradientTransform() {
   // We're creating a DOM wrapper, so we must tell GetAnimatedTransformList
   // to allocate the DOMSVGAnimatedTransformList if it hasn't already done so:
   return DOMSVGAnimatedTransformList::GetDOMWrapper(
       GetAnimatedTransformList(DO_ALLOCATE), this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGGradientElement::SpreadMethod() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGGradientElement::SpreadMethod() {
   return mEnumAttributes[SPREADMETHOD].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGGradientElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGGradientElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // nsIContent methods
 
@@ -123,29 +124,29 @@ SVGLinearGradientElement::SVGLinearGradi
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGLinearGradientElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGLinearGradientElement::X1() {
+already_AddRefed<DOMSVGAnimatedLength> SVGLinearGradientElement::X1() {
   return mLengthAttributes[ATTR_X1].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGLinearGradientElement::Y1() {
+already_AddRefed<DOMSVGAnimatedLength> SVGLinearGradientElement::Y1() {
   return mLengthAttributes[ATTR_Y1].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGLinearGradientElement::X2() {
+already_AddRefed<DOMSVGAnimatedLength> SVGLinearGradientElement::X2() {
   return mLengthAttributes[ATTR_X2].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGLinearGradientElement::Y2() {
+already_AddRefed<DOMSVGAnimatedLength> SVGLinearGradientElement::Y2() {
   return mLengthAttributes[ATTR_Y2].ToDOMAnimatedLength(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 SVGAnimatedTransformList* SVGGradientElement::GetAnimatedTransformList(
     uint32_t aFlags) {
@@ -191,37 +192,37 @@ SVGRadialGradientElement::SVGRadialGradi
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGRadialGradientElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGRadialGradientElement::Cx() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRadialGradientElement::Cx() {
   return mLengthAttributes[ATTR_CX].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRadialGradientElement::Cy() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRadialGradientElement::Cy() {
   return mLengthAttributes[ATTR_CY].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRadialGradientElement::R() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRadialGradientElement::R() {
   return mLengthAttributes[ATTR_R].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRadialGradientElement::Fx() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRadialGradientElement::Fx() {
   return mLengthAttributes[ATTR_FX].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRadialGradientElement::Fy() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRadialGradientElement::Fy() {
   return mLengthAttributes[ATTR_FY].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRadialGradientElement::Fr() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRadialGradientElement::Fr() {
   return mLengthAttributes[ATTR_FR].ToDOMAnimatedLength(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 SVGElement::LengthAttributesInfo SVGRadialGradientElement::GetLengthInfo() {
   return LengthAttributesInfo(mLengthAttributes, sLengthInfo,
--- a/dom/svg/SVGGradientElement.h
+++ b/dom/svg/SVGGradientElement.h
@@ -49,20 +49,20 @@ class SVGGradientElement : public SVGGra
 
   virtual SVGAnimatedTransformList* GetAnimatedTransformList(
       uint32_t aFlags = 0) override;
   virtual nsStaticAtom* GetTransformListAttrName() const override {
     return nsGkAtoms::gradientTransform;
   }
 
   // WebIDL
-  already_AddRefed<SVGAnimatedEnumeration> GradientUnits();
+  already_AddRefed<DOMSVGAnimatedEnumeration> GradientUnits();
   already_AddRefed<DOMSVGAnimatedTransformList> GradientTransform();
-  already_AddRefed<SVGAnimatedEnumeration> SpreadMethod();
-  already_AddRefed<SVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedEnumeration> SpreadMethod();
+  already_AddRefed<DOMSVGAnimatedString> Href();
 
  protected:
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
   enum { GRADIENTUNITS, SPREADMETHOD };
   SVGEnum mEnumAttributes[2];
   static SVGEnumMapping sSpreadMethodMap[];
@@ -91,20 +91,20 @@ class SVGLinearGradientElement : public 
       already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
   virtual JSObject* WrapNode(JSContext* aCx,
                              JS::Handle<JSObject*> aGivenProto) override;
 
  public:
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> X1();
-  already_AddRefed<SVGAnimatedLength> Y1();
-  already_AddRefed<SVGAnimatedLength> X2();
-  already_AddRefed<SVGAnimatedLength> Y2();
+  already_AddRefed<DOMSVGAnimatedLength> X1();
+  already_AddRefed<DOMSVGAnimatedLength> Y1();
+  already_AddRefed<DOMSVGAnimatedLength> X2();
+  already_AddRefed<DOMSVGAnimatedLength> Y2();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
 
   enum { ATTR_X1, ATTR_Y1, ATTR_X2, ATTR_Y2 };
   nsSVGLength2 mLengthAttributes[4];
   static LengthInfo sLengthInfo[4];
 };
@@ -124,22 +124,22 @@ class SVGRadialGradientElement : public 
       already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
   virtual JSObject* WrapNode(JSContext* aCx,
                              JS::Handle<JSObject*> aGivenProto) override;
 
  public:
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> Cx();
-  already_AddRefed<SVGAnimatedLength> Cy();
-  already_AddRefed<SVGAnimatedLength> R();
-  already_AddRefed<SVGAnimatedLength> Fx();
-  already_AddRefed<SVGAnimatedLength> Fy();
-  already_AddRefed<SVGAnimatedLength> Fr();
+  already_AddRefed<DOMSVGAnimatedLength> Cx();
+  already_AddRefed<DOMSVGAnimatedLength> Cy();
+  already_AddRefed<DOMSVGAnimatedLength> R();
+  already_AddRefed<DOMSVGAnimatedLength> Fx();
+  already_AddRefed<DOMSVGAnimatedLength> Fy();
+  already_AddRefed<DOMSVGAnimatedLength> Fr();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
 
   enum { ATTR_CX, ATTR_CY, ATTR_R, ATTR_FX, ATTR_FY, ATTR_FR };
   nsSVGLength2 mLengthAttributes[6];
   static LengthInfo sLengthInfo[6];
 };
--- a/dom/svg/SVGImageElement.cpp
+++ b/dom/svg/SVGImageElement.cpp
@@ -65,38 +65,38 @@ SVGImageElement::~SVGImageElement() { De
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGImageElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGImageElement::X() {
+already_AddRefed<DOMSVGAnimatedLength> SVGImageElement::X() {
   return mLengthAttributes[ATTR_X].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGImageElement::Y() {
+already_AddRefed<DOMSVGAnimatedLength> SVGImageElement::Y() {
   return mLengthAttributes[ATTR_Y].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGImageElement::Width() {
+already_AddRefed<DOMSVGAnimatedLength> SVGImageElement::Width() {
   return mLengthAttributes[ATTR_WIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGImageElement::Height() {
+already_AddRefed<DOMSVGAnimatedLength> SVGImageElement::Height() {
   return mLengthAttributes[ATTR_HEIGHT].ToDOMAnimatedLength(this);
 }
 
 already_AddRefed<DOMSVGAnimatedPreserveAspectRatio>
 SVGImageElement::PreserveAspectRatio() {
   return mPreserveAspectRatio.ToDOMAnimatedPreserveAspectRatio(this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGImageElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGImageElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 void SVGImageElement::GetDecoding(nsAString& aValue) {
   GetEnumAttr(nsGkAtoms::decoding, kDecodingTableDefault->tag, aValue);
 }
--- a/dom/svg/SVGImageElement.h
+++ b/dom/svg/SVGImageElement.h
@@ -76,22 +76,22 @@ class SVGImageElement : public SVGImageE
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   nsresult CopyInnerTo(mozilla::dom::Element* aDest);
 
   void MaybeLoadSVGImage();
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> X();
-  already_AddRefed<SVGAnimatedLength> Y();
-  already_AddRefed<SVGAnimatedLength> Width();
-  already_AddRefed<SVGAnimatedLength> Height();
+  already_AddRefed<DOMSVGAnimatedLength> X();
+  already_AddRefed<DOMSVGAnimatedLength> Y();
+  already_AddRefed<DOMSVGAnimatedLength> Width();
+  already_AddRefed<DOMSVGAnimatedLength> Height();
   already_AddRefed<DOMSVGAnimatedPreserveAspectRatio> PreserveAspectRatio();
-  already_AddRefed<SVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedString> Href();
 
   void SetDecoding(const nsAString& aDecoding, ErrorResult& aError) {
     SetAttr(nsGkAtoms::decoding, aDecoding, aError);
   }
   void GetDecoding(nsAString& aValue);
 
  protected:
   nsresult LoadSVGImage(bool aForce, bool aNotify);
--- a/dom/svg/SVGInteger.cpp
+++ b/dom/svg/SVGInteger.cpp
@@ -67,17 +67,17 @@ void SVGInteger::SetAnimValue(int aValue
   if (mIsAnimated && aValue == mAnimVal) {
     return;
   }
   mAnimVal = aValue;
   mIsAnimated = true;
   aSVGElement->DidAnimateInteger(mAttrEnum);
 }
 
-already_AddRefed<SVGAnimatedInteger> SVGInteger::ToDOMAnimatedInteger(
+already_AddRefed<DOMSVGAnimatedInteger> SVGInteger::ToDOMAnimatedInteger(
     SVGElement *aSVGElement) {
   RefPtr<DOMAnimatedInteger> domAnimatedInteger =
       sSVGAnimatedIntegerTearoffTable.GetTearoff(this);
   if (!domAnimatedInteger) {
     domAnimatedInteger = new DOMAnimatedInteger(this, aSVGElement);
     sSVGAnimatedIntegerTearoffTable.AddTearoff(this, domAnimatedInteger);
   }
 
--- a/dom/svg/SVGInteger.h
+++ b/dom/svg/SVGInteger.h
@@ -4,17 +4,17 @@
  * 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/. */
 
 #ifndef __NS_SVGINTEGER_H__
 #define __NS_SVGINTEGER_H__
 
 #include "nsCycleCollectionParticipant.h"
 #include "nsError.h"
-#include "SVGAnimatedInteger.h"
+#include "DOMSVGAnimatedInteger.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/SMILAttr.h"
 #include "mozilla/UniquePtr.h"
 #include "mozilla/dom/SVGElement.h"
 
 namespace mozilla {
 
 class SMILValue;
@@ -45,31 +45,31 @@ class SVGInteger {
 
   // Returns true if the animated value of this integer has been explicitly
   // set (either by animation, or by taking on the base value which has been
   // explicitly set by markup or a DOM call), false otherwise.
   // If this returns false, the animated value is still valid, that is,
   // usable, and represents the default base value of the attribute.
   bool IsExplicitlySet() const { return mIsAnimated || mIsBaseSet; }
 
-  already_AddRefed<mozilla::dom::SVGAnimatedInteger> ToDOMAnimatedInteger(
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedInteger> ToDOMAnimatedInteger(
       SVGElement* aSVGElement);
   mozilla::UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
  private:
   int32_t mAnimVal;
   int32_t mBaseVal;
   uint8_t mAttrEnum;  // element specified tracking for attribute
   bool mIsAnimated;
   bool mIsBaseSet;
 
  public:
-  struct DOMAnimatedInteger final : public mozilla::dom::SVGAnimatedInteger {
+  struct DOMAnimatedInteger final : public mozilla::dom::DOMSVGAnimatedInteger {
     DOMAnimatedInteger(SVGInteger* aVal, SVGElement* aSVGElement)
-        : mozilla::dom::SVGAnimatedInteger(aSVGElement), mVal(aVal) {}
+        : mozilla::dom::DOMSVGAnimatedInteger(aSVGElement), mVal(aVal) {}
     virtual ~DOMAnimatedInteger();
 
     SVGInteger* mVal;  // kept alive because it belongs to content
 
     virtual int32_t BaseVal() override { return mVal->GetBaseValue(); }
     virtual void SetBaseVal(int32_t aValue) override {
       mVal->SetBaseValue(aValue, mSVGElement);
     }
--- a/dom/svg/SVGIntegerPair.cpp
+++ b/dom/svg/SVGIntegerPair.cpp
@@ -131,17 +131,17 @@ void SVGIntegerPair::SetAnimValue(const 
     return;
   }
   mAnimVal[0] = aValue[0];
   mAnimVal[1] = aValue[1];
   mIsAnimated = true;
   aSVGElement->DidAnimateIntegerPair(mAttrEnum);
 }
 
-already_AddRefed<SVGAnimatedInteger> SVGIntegerPair::ToDOMAnimatedInteger(
+already_AddRefed<DOMSVGAnimatedInteger> SVGIntegerPair::ToDOMAnimatedInteger(
     PairIndex aIndex, SVGElement* aSVGElement) {
   RefPtr<DOMAnimatedInteger> domAnimatedInteger =
       aIndex == eFirst ? sSVGFirstAnimatedIntegerTearoffTable.GetTearoff(this)
                        : sSVGSecondAnimatedIntegerTearoffTable.GetTearoff(this);
   if (!domAnimatedInteger) {
     domAnimatedInteger = new DOMAnimatedInteger(this, aIndex, aSVGElement);
     if (aIndex == eFirst) {
       sSVGFirstAnimatedIntegerTearoffTable.AddTearoff(this, domAnimatedInteger);
--- a/dom/svg/SVGIntegerPair.h
+++ b/dom/svg/SVGIntegerPair.h
@@ -2,22 +2,22 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef __NS_SVGINTEGERPAIR_H__
 #define __NS_SVGINTEGERPAIR_H__
 
+#include "DOMSVGAnimatedInteger.h"
 #include "nsCycleCollectionParticipant.h"
 #include "nsError.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/SMILAttr.h"
 #include "mozilla/UniquePtr.h"
-#include "mozilla/dom/SVGAnimatedInteger.h"
 
 namespace mozilla {
 
 class SMILValue;
 
 namespace dom {
 class SVGAnimationElement;
 class SVGElement;
@@ -53,32 +53,32 @@ class SVGIntegerPair {
 
   // Returns true if the animated value of this integer has been explicitly
   // set (either by animation, or by taking on the base value which has been
   // explicitly set by markup or a DOM call), false otherwise.
   // If this returns false, the animated value is still valid, that is,
   // usable, and represents the default base value of the attribute.
   bool IsExplicitlySet() const { return mIsAnimated || mIsBaseSet; }
 
-  already_AddRefed<mozilla::dom::SVGAnimatedInteger> ToDOMAnimatedInteger(
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedInteger> ToDOMAnimatedInteger(
       PairIndex aIndex, SVGElement* aSVGElement);
   mozilla::UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
  private:
   int32_t mAnimVal[2];
   int32_t mBaseVal[2];
   uint8_t mAttrEnum;  // element specified tracking for attribute
   bool mIsAnimated;
   bool mIsBaseSet;
 
  public:
-  struct DOMAnimatedInteger final : public mozilla::dom::SVGAnimatedInteger {
+  struct DOMAnimatedInteger final : public mozilla::dom::DOMSVGAnimatedInteger {
     DOMAnimatedInteger(SVGIntegerPair* aVal, PairIndex aIndex,
                        SVGElement* aSVGElement)
-        : mozilla::dom::SVGAnimatedInteger(aSVGElement),
+        : mozilla::dom::DOMSVGAnimatedInteger(aSVGElement),
           mVal(aVal),
           mIndex(aIndex) {}
     virtual ~DOMAnimatedInteger();
 
     SVGIntegerPair* mVal;  // kept alive because it belongs to content
     PairIndex mIndex;      // are we the first or second integer
 
     virtual int32_t BaseVal() override { return mVal->GetBaseValue(mIndex); }
--- a/dom/svg/SVGLineElement.cpp
+++ b/dom/svg/SVGLineElement.cpp
@@ -56,29 +56,29 @@ void SVGLineElement::MaybeAdjustForZeroL
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGLineElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGLineElement::X1() {
+already_AddRefed<DOMSVGAnimatedLength> SVGLineElement::X1() {
   return mLengthAttributes[ATTR_X1].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGLineElement::Y1() {
+already_AddRefed<DOMSVGAnimatedLength> SVGLineElement::Y1() {
   return mLengthAttributes[ATTR_Y1].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGLineElement::X2() {
+already_AddRefed<DOMSVGAnimatedLength> SVGLineElement::X2() {
   return mLengthAttributes[ATTR_X2].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGLineElement::Y2() {
+already_AddRefed<DOMSVGAnimatedLength> SVGLineElement::Y2() {
   return mLengthAttributes[ATTR_Y2].ToDOMAnimatedLength(this);
 }
 
 //----------------------------------------------------------------------
 // nsIContent methods
 
 NS_IMETHODIMP_(bool)
 SVGLineElement::IsAttributeMapped(const nsAtom* name) const {
--- a/dom/svg/SVGLineElement.h
+++ b/dom/svg/SVGLineElement.h
@@ -43,20 +43,20 @@ class SVGLineElement final : public SVGL
   virtual bool GetGeometryBounds(
       Rect* aBounds, const StrokeOptions& aStrokeOptions,
       const Matrix& aToBoundsSpace,
       const Matrix* aToNonScalingStrokeSpace = nullptr) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> X1();
-  already_AddRefed<SVGAnimatedLength> Y1();
-  already_AddRefed<SVGAnimatedLength> X2();
-  already_AddRefed<SVGAnimatedLength> Y2();
+  already_AddRefed<DOMSVGAnimatedLength> X1();
+  already_AddRefed<DOMSVGAnimatedLength> Y1();
+  already_AddRefed<DOMSVGAnimatedLength> X2();
+  already_AddRefed<DOMSVGAnimatedLength> Y2();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
 
   enum { ATTR_X1, ATTR_Y1, ATTR_X2, ATTR_Y2 };
   nsSVGLength2 mLengthAttributes[4];
   static LengthInfo sLengthInfo[4];
 };
--- a/dom/svg/SVGMPathElement.cpp
+++ b/dom/svg/SVGMPathElement.cpp
@@ -55,17 +55,17 @@ SVGMPathElement::SVGMPathElement(
 
 SVGMPathElement::~SVGMPathElement() { UnlinkHrefTarget(false); }
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGMPathElement)
 
-already_AddRefed<SVGAnimatedString> SVGMPathElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGMPathElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // nsIContent methods
 
--- a/dom/svg/SVGMPathElement.h
+++ b/dom/svg/SVGMPathElement.h
@@ -60,17 +60,17 @@ class SVGMPathElement final : public SVG
                                 bool aNotify) override;
 
   // Public helper method: If our xlink:href attribute links to a <path>
   // element, this method returns a pointer to that element. Otherwise,
   // this returns nullptr.
   SVGPathElement* GetReferencedPath();
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedString> Href();
 
  protected:
   /**
    * Helper that provides a reference to the 'path' element with the ID that is
    * referenced by the 'mpath' element's 'href' attribute, and that will
    * invalidate the parent of the 'mpath' and update mutation observers to the
    * new path element if the element that that ID identifies changes to a
    * different element (or none).
--- a/dom/svg/SVGMarkerElement.cpp
+++ b/dom/svg/SVGMarkerElement.cpp
@@ -2,20 +2,20 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #include "mozilla/dom/SVGMarkerElement.h"
 
 #include "nsGkAtoms.h"
+#include "DOMSVGAngle.h"
 #include "SVGAnimatedPreserveAspectRatio.h"
 #include "nsError.h"
 #include "mozilla/ArrayUtils.h"
-#include "mozilla/dom/DOMSVGAngle.h"
 #include "mozilla/dom/SVGGeometryElement.h"
 #include "mozilla/dom/SVGLengthBinding.h"
 #include "mozilla/dom/SVGMarkerElementBinding.h"
 #include "mozilla/gfx/Matrix.h"
 #include "mozilla/FloatingPoint.h"
 #include "mozilla/RefPtr.h"
 #include "SVGContentUtils.h"
 
@@ -73,41 +73,41 @@ already_AddRefed<SVGAnimatedRect> SVGMar
 
 already_AddRefed<DOMSVGAnimatedPreserveAspectRatio>
 SVGMarkerElement::PreserveAspectRatio() {
   return mPreserveAspectRatio.ToDOMAnimatedPreserveAspectRatio(this);
 }
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGMarkerElement::RefX() {
+already_AddRefed<DOMSVGAnimatedLength> SVGMarkerElement::RefX() {
   return mLengthAttributes[REFX].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGMarkerElement::RefY() {
+already_AddRefed<DOMSVGAnimatedLength> SVGMarkerElement::RefY() {
   return mLengthAttributes[REFY].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGMarkerElement::MarkerUnits() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGMarkerElement::MarkerUnits() {
   return mEnumAttributes[MARKERUNITS].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGMarkerElement::MarkerWidth() {
+already_AddRefed<DOMSVGAnimatedLength> SVGMarkerElement::MarkerWidth() {
   return mLengthAttributes[MARKERWIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGMarkerElement::MarkerHeight() {
+already_AddRefed<DOMSVGAnimatedLength> SVGMarkerElement::MarkerHeight() {
   return mLengthAttributes[MARKERHEIGHT].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGMarkerElement::OrientType() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGMarkerElement::OrientType() {
   return mOrient.ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedAngle> SVGMarkerElement::OrientAngle() {
+already_AddRefed<DOMSVGAnimatedAngle> SVGMarkerElement::OrientAngle() {
   return mOrient.ToDOMAnimatedAngle(this);
 }
 
 void SVGMarkerElement::SetOrientToAuto() {
   mOrient.SetBaseType(SVG_MARKER_ORIENT_AUTO, this);
 }
 
 void SVGMarkerElement::SetOrientToAngle(DOMSVGAngle& angle, ErrorResult& rv) {
--- a/dom/svg/SVGMarkerElement.h
+++ b/dom/svg/SVGMarkerElement.h
@@ -2,25 +2,25 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef mozilla_dom_SVGMarkerElement_h
 #define mozilla_dom_SVGMarkerElement_h
 
+#include "DOMSVGAnimatedAngle.h"
+#include "DOMSVGAnimatedEnumeration.h"
 #include "nsAutoPtr.h"
 #include "SVGAnimatedPreserveAspectRatio.h"
 #include "SVGEnum.h"
 #include "nsSVGLength2.h"
 #include "SVGOrient.h"
 #include "SVGViewBox.h"
 #include "mozilla/Attributes.h"
-#include "mozilla/dom/SVGAnimatedAngle.h"
-#include "mozilla/dom/SVGAnimatedEnumeration.h"
 #include "mozilla/dom/SVGElement.h"
 #include "mozilla/dom/SVGMarkerElementBinding.h"
 
 class nsSVGMarkerFrame;
 
 nsresult NS_NewSVGMarkerElement(
     nsIContent** aResult, already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo);
 
@@ -59,23 +59,23 @@ class SVGMarkerElement : public SVGMarke
   SVGViewBoxRect GetViewBoxRect();
   gfx::Matrix GetViewBoxTransform();
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
   already_AddRefed<SVGAnimatedRect> ViewBox();
   already_AddRefed<DOMSVGAnimatedPreserveAspectRatio> PreserveAspectRatio();
-  already_AddRefed<SVGAnimatedLength> RefX();
-  already_AddRefed<SVGAnimatedLength> RefY();
-  already_AddRefed<SVGAnimatedEnumeration> MarkerUnits();
-  already_AddRefed<SVGAnimatedLength> MarkerWidth();
-  already_AddRefed<SVGAnimatedLength> MarkerHeight();
-  already_AddRefed<SVGAnimatedEnumeration> OrientType();
-  already_AddRefed<SVGAnimatedAngle> OrientAngle();
+  already_AddRefed<DOMSVGAnimatedLength> RefX();
+  already_AddRefed<DOMSVGAnimatedLength> RefY();
+  already_AddRefed<DOMSVGAnimatedEnumeration> MarkerUnits();
+  already_AddRefed<DOMSVGAnimatedLength> MarkerWidth();
+  already_AddRefed<DOMSVGAnimatedLength> MarkerHeight();
+  already_AddRefed<DOMSVGAnimatedEnumeration> OrientType();
+  already_AddRefed<DOMSVGAnimatedAngle> OrientAngle();
   void SetOrientToAuto();
   void SetOrientToAngle(DOMSVGAngle& angle, ErrorResult& rv);
 
  protected:
   void SetParentCoordCtxProvider(SVGViewportElement* aContext);
 
   virtual LengthAttributesInfo GetLengthInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
--- a/dom/svg/SVGMaskElement.cpp
+++ b/dom/svg/SVGMaskElement.cpp
@@ -52,37 +52,37 @@ SVGMaskElement::SVGMaskElement(
 
 //----------------------------------------------------------------------
 // nsINode method
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGMaskElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedEnumeration> SVGMaskElement::MaskUnits() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGMaskElement::MaskUnits() {
   return mEnumAttributes[MASKUNITS].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGMaskElement::MaskContentUnits() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGMaskElement::MaskContentUnits() {
   return mEnumAttributes[MASKCONTENTUNITS].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGMaskElement::X() {
+already_AddRefed<DOMSVGAnimatedLength> SVGMaskElement::X() {
   return mLengthAttributes[ATTR_X].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGMaskElement::Y() {
+already_AddRefed<DOMSVGAnimatedLength> SVGMaskElement::Y() {
   return mLengthAttributes[ATTR_Y].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGMaskElement::Width() {
+already_AddRefed<DOMSVGAnimatedLength> SVGMaskElement::Width() {
   return mLengthAttributes[ATTR_WIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGMaskElement::Height() {
+already_AddRefed<DOMSVGAnimatedLength> SVGMaskElement::Height() {
   return mLengthAttributes[ATTR_HEIGHT].ToDOMAnimatedLength(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 /* virtual */
 bool SVGMaskElement::HasValidDimensions() const {
--- a/dom/svg/SVGMaskElement.h
+++ b/dom/svg/SVGMaskElement.h
@@ -38,22 +38,22 @@ class SVGMaskElement final : public SVGM
   // nsIContent interface
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
   NS_IMETHOD_(bool) IsAttributeMapped(const nsAtom* aAttribute) const override;
 
   // nsSVGSVGElement methods:
   virtual bool HasValidDimensions() const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedEnumeration> MaskUnits();
-  already_AddRefed<SVGAnimatedEnumeration> MaskContentUnits();
-  already_AddRefed<SVGAnimatedLength> X();
-  already_AddRefed<SVGAnimatedLength> Y();
-  already_AddRefed<SVGAnimatedLength> Width();
-  already_AddRefed<SVGAnimatedLength> Height();
+  already_AddRefed<DOMSVGAnimatedEnumeration> MaskUnits();
+  already_AddRefed<DOMSVGAnimatedEnumeration> MaskContentUnits();
+  already_AddRefed<DOMSVGAnimatedLength> X();
+  already_AddRefed<DOMSVGAnimatedLength> Y();
+  already_AddRefed<DOMSVGAnimatedLength> Width();
+  already_AddRefed<DOMSVGAnimatedLength> Height();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
 
   enum { ATTR_X, ATTR_Y, ATTR_WIDTH, ATTR_HEIGHT };
   nsSVGLength2 mLengthAttributes[4];
   static LengthInfo sLengthInfo[4];
--- a/dom/svg/SVGMatrix.h
+++ b/dom/svg/SVGMatrix.h
@@ -32,17 +32,17 @@
  * Pre-multiplying may look wrong if you're only familiar with the SVG
  * convention, but in that case hopefully the above explanation clears things
  * up.
  */
 
 #ifndef mozilla_dom_SVGMatrix_h
 #define mozilla_dom_SVGMatrix_h
 
-#include "mozilla/dom/DOMSVGTransform.h"
+#include "DOMSVGTransform.h"
 #include "gfxMatrix.h"
 #include "nsCycleCollectionParticipant.h"
 #include "nsWrapperCache.h"
 #include "mozilla/Attributes.h"
 
 namespace mozilla {
 namespace dom {
 
--- a/dom/svg/SVGNumberPair.cpp
+++ b/dom/svg/SVGNumberPair.cpp
@@ -124,17 +124,17 @@ void SVGNumberPair::SetAnimValue(const f
     return;
   }
   mAnimVal[0] = aValue[0];
   mAnimVal[1] = aValue[1];
   mIsAnimated = true;
   aSVGElement->DidAnimateNumberPair(mAttrEnum);
 }
 
-already_AddRefed<SVGAnimatedNumber> SVGNumberPair::ToDOMAnimatedNumber(
+already_AddRefed<DOMSVGAnimatedNumber> SVGNumberPair::ToDOMAnimatedNumber(
     PairIndex aIndex, SVGElement* aSVGElement) {
   RefPtr<DOMAnimatedNumber> domAnimatedNumber =
       aIndex == eFirst ? sSVGFirstAnimatedNumberTearoffTable.GetTearoff(this)
                        : sSVGSecondAnimatedNumberTearoffTable.GetTearoff(this);
   if (!domAnimatedNumber) {
     domAnimatedNumber = new DOMAnimatedNumber(this, aIndex, aSVGElement);
     if (aIndex == eFirst) {
       sSVGFirstAnimatedNumberTearoffTable.AddTearoff(this, domAnimatedNumber);
--- a/dom/svg/SVGNumberPair.h
+++ b/dom/svg/SVGNumberPair.h
@@ -2,20 +2,20 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef __NS_SVGNUMBERPAIR_H__
 #define __NS_SVGNUMBERPAIR_H__
 
+#include "DOMSVGAnimatedNumber.h"
 #include "nsCycleCollectionParticipant.h"
 #include "nsError.h"
 #include "nsMathUtils.h"
-#include "mozilla/dom/SVGAnimatedNumber.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/FloatingPoint.h"
 #include "mozilla/SMILAttr.h"
 #include "mozilla/UniquePtr.h"
 
 namespace mozilla {
 
 class SMILValue;
@@ -54,32 +54,34 @@ class SVGNumberPair {
 
   // Returns true if the animated value of this number has been explicitly
   // set (either by animation, or by taking on the base value which has been
   // explicitly set by markup or a DOM call), false otherwise.
   // If this returns false, the animated value is still valid, that is,
   // usable, and represents the default base value of the attribute.
   bool IsExplicitlySet() const { return mIsAnimated || mIsBaseSet; }
 
-  already_AddRefed<mozilla::dom::SVGAnimatedNumber> ToDOMAnimatedNumber(
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedNumber> ToDOMAnimatedNumber(
       PairIndex aIndex, SVGElement* aSVGElement);
   mozilla::UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
  private:
   float mAnimVal[2];
   float mBaseVal[2];
   uint8_t mAttrEnum;  // element specified tracking for attribute
   bool mIsAnimated;
   bool mIsBaseSet;
 
  public:
-  struct DOMAnimatedNumber final : public mozilla::dom::SVGAnimatedNumber {
+  // DOM wrapper class for the (DOM)SVGAnimatedNumber interface where the
+  // wrapped class is SVGNumberPair.
+  struct DOMAnimatedNumber final : public mozilla::dom::DOMSVGAnimatedNumber {
     DOMAnimatedNumber(SVGNumberPair* aVal, PairIndex aIndex,
                       SVGElement* aSVGElement)
-        : mozilla::dom::SVGAnimatedNumber(aSVGElement),
+        : mozilla::dom::DOMSVGAnimatedNumber(aSVGElement),
           mVal(aVal),
           mIndex(aIndex) {}
     virtual ~DOMAnimatedNumber();
 
     SVGNumberPair* mVal;  // kept alive because it belongs to content
     PairIndex mIndex;     // are we the first or second number
 
     virtual float BaseVal() override { return mVal->GetBaseValue(mIndex); }
--- a/dom/svg/SVGOrient.cpp
+++ b/dom/svg/SVGOrient.cpp
@@ -4,38 +4,38 @@
  * 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/. */
 
 #include "SVGOrient.h"
 
 #include "mozilla/ArrayUtils.h"
 #include "mozilla/Move.h"
 #include "mozilla/SMILValue.h"
-#include "mozilla/dom/DOMSVGAngle.h"
-#include "mozilla/dom/SVGAnimatedAngle.h"
 #include "mozilla/dom/SVGMarkerElement.h"
+#include "DOMSVGAnimatedAngle.h"
+#include "DOMSVGAngle.h"
 #include "nsContentUtils.h"
+#include "nsTextFormatter.h"
 #include "SVGAttrTearoffTable.h"
 #include "SVGOrientSMILType.h"
-#include "nsTextFormatter.h"
 
 using namespace mozilla::dom;
 using namespace mozilla::dom::SVGAngle_Binding;
 using namespace mozilla::dom::SVGMarkerElement_Binding;
 
 namespace mozilla {
 
 static const nsStaticAtom* const angleUnitMap[] = {
     nullptr, /* SVG_ANGLETYPE_UNKNOWN */
     nullptr, /* SVG_ANGLETYPE_UNSPECIFIED */
     nsGkAtoms::deg, nsGkAtoms::rad, nsGkAtoms::grad};
 
-static SVGAttrTearoffTable<SVGOrient, SVGAnimatedEnumeration>
+static SVGAttrTearoffTable<SVGOrient, DOMSVGAnimatedEnumeration>
     sSVGAnimatedEnumTearoffTable;
-static SVGAttrTearoffTable<SVGOrient, SVGAnimatedAngle>
+static SVGAttrTearoffTable<SVGOrient, DOMSVGAnimatedAngle>
     sSVGAnimatedAngleTearoffTable;
 static SVGAttrTearoffTable<SVGOrient, DOMSVGAngle> sBaseSVGAngleTearoffTable;
 static SVGAttrTearoffTable<SVGOrient, DOMSVGAngle> sAnimSVGAngleTearoffTable;
 
 /* Helper functions */
 
 //----------------------------------------------------------------------
 // Helper class: AutoChangeOrientNotifier
@@ -364,41 +364,41 @@ void SVGOrient::SetAnimType(SVGEnumValue
   }
   mAnimVal = .0f;
   mAnimValUnit = SVG_ANGLETYPE_UNSPECIFIED;
   mAnimType = aValue;
   mIsAnimated = true;
   aSVGElement->DidAnimateOrient();
 }
 
-already_AddRefed<SVGAnimatedAngle> SVGOrient::ToDOMAnimatedAngle(
+already_AddRefed<DOMSVGAnimatedAngle> SVGOrient::ToDOMAnimatedAngle(
     SVGElement* aSVGElement) {
-  RefPtr<SVGAnimatedAngle> domAnimatedAngle =
+  RefPtr<DOMSVGAnimatedAngle> domAnimatedAngle =
       sSVGAnimatedAngleTearoffTable.GetTearoff(this);
   if (!domAnimatedAngle) {
-    domAnimatedAngle = new SVGAnimatedAngle(this, aSVGElement);
+    domAnimatedAngle = new DOMSVGAnimatedAngle(this, aSVGElement);
     sSVGAnimatedAngleTearoffTable.AddTearoff(this, domAnimatedAngle);
   }
 
   return domAnimatedAngle.forget();
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGOrient::ToDOMAnimatedEnum(
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGOrient::ToDOMAnimatedEnum(
     SVGElement* aSVGElement) {
-  RefPtr<SVGAnimatedEnumeration> domAnimatedEnum =
+  RefPtr<DOMSVGAnimatedEnumeration> domAnimatedEnum =
       sSVGAnimatedEnumTearoffTable.GetTearoff(this);
   if (!domAnimatedEnum) {
     domAnimatedEnum = new DOMAnimatedEnum(this, aSVGElement);
     sSVGAnimatedEnumTearoffTable.AddTearoff(this, domAnimatedEnum);
   }
 
   return domAnimatedEnum.forget();
 }
 
-SVGAnimatedAngle::~SVGAnimatedAngle() {
+DOMSVGAnimatedAngle::~DOMSVGAnimatedAngle() {
   sSVGAnimatedAngleTearoffTable.RemoveTearoff(mVal);
 }
 
 SVGOrient::DOMAnimatedEnum::~DOMAnimatedEnum() {
   sSVGAnimatedEnumTearoffTable.RemoveTearoff(mVal);
 }
 
 // we want to avoid exposing SVG_MARKER_ORIENT_AUTO_START_REVERSE to
--- a/dom/svg/SVGOrient.h
+++ b/dom/svg/SVGOrient.h
@@ -2,43 +2,43 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef __NS_SVGORIENT_H__
 #define __NS_SVGORIENT_H__
 
+#include "DOMSVGAnimatedEnumeration.h"
 #include "nsError.h"
 #include "SVGEnum.h"
 #include "mozilla/AlreadyAddRefed.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/SMILAttr.h"
 #include "mozilla/dom/SVGAngleBinding.h"
-#include "mozilla/dom/SVGAnimatedEnumeration.h"
 #include "mozilla/dom/SVGMarkerElementBinding.h"
 #include "mozilla/UniquePtr.h"
 
 class nsISupports;
 
 namespace mozilla {
 
 class SMILValue;
 
 namespace dom {
 class DOMSVGAngle;
-class SVGAnimatedAngle;
+class DOMSVGAnimatedAngle;
 class SVGAnimationElement;
 class SVGElement;
 }  // namespace dom
 
 class SVGOrient {
   friend class AutoChangeOrientNotifier;
   friend class mozilla::dom::DOMSVGAngle;
-  friend class mozilla::dom::SVGAnimatedAngle;
+  friend class mozilla::dom::DOMSVGAnimatedAngle;
   typedef mozilla::dom::SVGElement SVGElement;
 
  public:
   void Init() {
     mAnimVal = mBaseVal = .0f;
     mAnimType = mBaseType =
         dom::SVGMarkerElement_Binding::SVG_MARKER_ORIENT_ANGLE;
     mAnimValUnit = mBaseValUnit =
@@ -67,19 +67,19 @@ class SVGOrient {
   void SetAnimType(SVGEnumValue aType, SVGElement* aSVGElement);
 
   uint8_t GetBaseValueUnit() const { return mBaseValUnit; }
   uint8_t GetAnimValueUnit() const { return mAnimValUnit; }
   float GetBaseValInSpecifiedUnits() const { return mBaseVal; }
   float GetAnimValInSpecifiedUnits() const { return mAnimVal; }
 
   static nsresult ToDOMSVGAngle(nsISupports** aResult);
-  already_AddRefed<dom::SVGAnimatedAngle> ToDOMAnimatedAngle(
+  already_AddRefed<dom::DOMSVGAnimatedAngle> ToDOMAnimatedAngle(
       SVGElement* aSVGElement);
-  already_AddRefed<dom::SVGAnimatedEnumeration> ToDOMAnimatedEnum(
+  already_AddRefed<dom::DOMSVGAnimatedEnumeration> ToDOMAnimatedEnum(
       SVGElement* aSVGElement);
   UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
   static bool GetValueFromString(const nsAString& aString, float& aValue,
                                  uint16_t* aUnitType);
   static float GetDegreesPerUnit(uint8_t aUnit);
 
  private:
@@ -94,24 +94,26 @@ class SVGOrient {
   void SetBaseValueInSpecifiedUnits(float aValue, SVGElement* aSVGElement);
   nsresult NewValueSpecifiedUnits(uint16_t aUnitType, float aValue,
                                   SVGElement* aSVGElement);
   nsresult ConvertToSpecifiedUnits(uint16_t aUnitType, SVGElement* aSVGElement);
   already_AddRefed<dom::DOMSVGAngle> ToDOMBaseVal(SVGElement* aSVGElement);
   already_AddRefed<dom::DOMSVGAngle> ToDOMAnimVal(SVGElement* aSVGElement);
 
  public:
-  struct DOMAnimatedEnum final : public dom::SVGAnimatedEnumeration {
+  // DOM wrapper class for the (DOM)SVGAnimatedEnumeration interface where the
+  // wrapped class is SVGOrient.
+  struct DOMAnimatedEnum final : public dom::DOMSVGAnimatedEnumeration {
     DOMAnimatedEnum(SVGOrient* aVal, SVGElement* aSVGElement)
-        : SVGAnimatedEnumeration(aSVGElement), mVal(aVal) {}
+        : DOMSVGAnimatedEnumeration(aSVGElement), mVal(aVal) {}
     ~DOMAnimatedEnum();
 
     SVGOrient* mVal;  // kept alive because it belongs to content
 
-    using mozilla::dom::SVGAnimatedEnumeration::SetBaseVal;
+    using mozilla::dom::DOMSVGAnimatedEnumeration::SetBaseVal;
     uint16_t BaseVal() override { return Sanitize(mVal->mBaseType); }
     void SetBaseVal(uint16_t aBaseVal, ErrorResult& aRv) override {
       aRv = mVal->SetBaseType(aBaseVal, mSVGElement);
     }
     uint16_t AnimVal() override {
       // Script may have modified animation parameters or timeline -- DOM
       // getters need to flush any resample requests to reflect these
       // modifications.
--- a/dom/svg/SVGOrientSMILType.h
+++ b/dom/svg/SVGOrientSMILType.h
@@ -13,18 +13,18 @@
 /**
  * This SMILType class is a special case for the 'orient' attribute on SVG's
  * 'marker' element.
  *
  *   orient = "auto | auto-start-reverse | <angle>"
  *
  * Unusually, this attribute doesn't have just a single corresponding DOM
  * property, but rather is split into two properties: 'orientType' (of type
- * SVGAnimatedEnumeration) and 'orientAngle' (of type SVGAnimatedAngle). If
- * 'orientType.animVal' is SVG_MARKER_ORIENT_ANGLE, then
+ * DOMSVGAnimatedEnumeration) and 'orientAngle' (of type DOMSVGAnimatedAngle).
+ * If 'orientType.animVal' is SVG_MARKER_ORIENT_ANGLE, then
  * 'orientAngle.animVal' contains the angle that is being used. The lacuna
  * value is 0.
  *
  * The SVG 2 specification does not define a
  * SVG_MARKER_ORIENT_AUTO_START_REVERSE constant value for orientType to use;
  * instead, if the attribute is set to "auto-start-reverse",
  * SVG_MARKER_ORIENT_UNKNOWN is used.  Internally, however, we do use a
  * constant with this name.
--- a/dom/svg/SVGPatternElement.cpp
+++ b/dom/svg/SVGPatternElement.cpp
@@ -69,50 +69,50 @@ already_AddRefed<SVGAnimatedRect> SVGPat
 
 already_AddRefed<DOMSVGAnimatedPreserveAspectRatio>
 SVGPatternElement::PreserveAspectRatio() {
   return mPreserveAspectRatio.ToDOMAnimatedPreserveAspectRatio(this);
 }
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedEnumeration> SVGPatternElement::PatternUnits() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGPatternElement::PatternUnits() {
   return mEnumAttributes[PATTERNUNITS].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration>
+already_AddRefed<DOMSVGAnimatedEnumeration>
 SVGPatternElement::PatternContentUnits() {
   return mEnumAttributes[PATTERNCONTENTUNITS].ToDOMAnimatedEnum(this);
 }
 
 already_AddRefed<DOMSVGAnimatedTransformList>
 SVGPatternElement::PatternTransform() {
   // We're creating a DOM wrapper, so we must tell GetAnimatedTransformList
   // to allocate the DOMSVGAnimatedTransformList if it hasn't already done so:
   return DOMSVGAnimatedTransformList::GetDOMWrapper(
       GetAnimatedTransformList(DO_ALLOCATE), this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGPatternElement::X() {
+already_AddRefed<DOMSVGAnimatedLength> SVGPatternElement::X() {
   return mLengthAttributes[ATTR_X].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGPatternElement::Y() {
+already_AddRefed<DOMSVGAnimatedLength> SVGPatternElement::Y() {
   return mLengthAttributes[ATTR_Y].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGPatternElement::Width() {
+already_AddRefed<DOMSVGAnimatedLength> SVGPatternElement::Width() {
   return mLengthAttributes[ATTR_WIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGPatternElement::Height() {
+already_AddRefed<DOMSVGAnimatedLength> SVGPatternElement::Height() {
   return mLengthAttributes[ATTR_HEIGHT].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGPatternElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGPatternElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // nsIContent methods
 
--- a/dom/svg/SVGPatternElement.h
+++ b/dom/svg/SVGPatternElement.h
@@ -55,24 +55,24 @@ class SVGPatternElement final : public S
       uint32_t aFlags = 0) override;
   virtual nsStaticAtom* GetTransformListAttrName() const override {
     return nsGkAtoms::patternTransform;
   }
 
   // WebIDL
   already_AddRefed<SVGAnimatedRect> ViewBox();
   already_AddRefed<DOMSVGAnimatedPreserveAspectRatio> PreserveAspectRatio();
-  already_AddRefed<SVGAnimatedEnumeration> PatternUnits();
-  already_AddRefed<SVGAnimatedEnumeration> PatternContentUnits();
+  already_AddRefed<DOMSVGAnimatedEnumeration> PatternUnits();
+  already_AddRefed<DOMSVGAnimatedEnumeration> PatternContentUnits();
   already_AddRefed<DOMSVGAnimatedTransformList> PatternTransform();
-  already_AddRefed<SVGAnimatedLength> X();
-  already_AddRefed<SVGAnimatedLength> Y();
-  already_AddRefed<SVGAnimatedLength> Width();
-  already_AddRefed<SVGAnimatedLength> Height();
-  already_AddRefed<SVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedLength> X();
+  already_AddRefed<DOMSVGAnimatedLength> Y();
+  already_AddRefed<DOMSVGAnimatedLength> Width();
+  already_AddRefed<DOMSVGAnimatedLength> Height();
+  already_AddRefed<DOMSVGAnimatedString> Href();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual SVGViewBox* GetViewBox() override;
   virtual SVGAnimatedPreserveAspectRatio* GetPreserveAspectRatio() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
--- a/dom/svg/SVGRectElement.cpp
+++ b/dom/svg/SVGRectElement.cpp
@@ -16,17 +16,17 @@
 
 NS_IMPL_NS_NEW_SVG_ELEMENT(Rect)
 
 using namespace mozilla::gfx;
 
 namespace mozilla {
 namespace dom {
 
-class SVGAnimatedLength;
+class DOMSVGAnimatedLength;
 
 JSObject* SVGRectElement::WrapNode(JSContext* aCx,
                                    JS::Handle<JSObject*> aGivenProto) {
   return SVGRectElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 SVGElement::LengthInfo SVGRectElement::sLengthInfo[6] = {
     {nsGkAtoms::x, 0, SVGLength_Binding::SVG_LENGTHTYPE_NUMBER,
@@ -51,37 +51,37 @@ SVGRectElement::SVGRectElement(
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGRectElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGRectElement::X() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRectElement::X() {
   return mLengthAttributes[ATTR_X].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRectElement::Y() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRectElement::Y() {
   return mLengthAttributes[ATTR_Y].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRectElement::Width() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRectElement::Width() {
   return mLengthAttributes[ATTR_WIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRectElement::Height() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRectElement::Height() {
   return mLengthAttributes[ATTR_HEIGHT].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRectElement::Rx() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRectElement::Rx() {
   return mLengthAttributes[ATTR_RX].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGRectElement::Ry() {
+already_AddRefed<DOMSVGAnimatedLength> SVGRectElement::Ry() {
   return mLengthAttributes[ATTR_RY].ToDOMAnimatedLength(this);
 }
 
 //----------------------------------------------------------------------
 // SVGElement methods
 
 /* virtual */
 bool SVGRectElement::HasValidDimensions() const {
--- a/dom/svg/SVGRectElement.h
+++ b/dom/svg/SVGRectElement.h
@@ -38,22 +38,22 @@ class SVGRectElement final : public SVGR
       const Matrix* aToNonScalingStrokeSpace = nullptr) override;
   virtual void GetAsSimplePath(SimplePath* aSimplePath) override;
   virtual already_AddRefed<Path> BuildPath(
       PathBuilder* aBuilder = nullptr) override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> X();
-  already_AddRefed<SVGAnimatedLength> Y();
-  already_AddRefed<SVGAnimatedLength> Height();
-  already_AddRefed<SVGAnimatedLength> Width();
-  already_AddRefed<SVGAnimatedLength> Rx();
-  already_AddRefed<SVGAnimatedLength> Ry();
+  already_AddRefed<DOMSVGAnimatedLength> X();
+  already_AddRefed<DOMSVGAnimatedLength> Y();
+  already_AddRefed<DOMSVGAnimatedLength> Height();
+  already_AddRefed<DOMSVGAnimatedLength> Width();
+  already_AddRefed<DOMSVGAnimatedLength> Rx();
+  already_AddRefed<DOMSVGAnimatedLength> Ry();
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
 
   enum { ATTR_X, ATTR_Y, ATTR_WIDTH, ATTR_HEIGHT, ATTR_RX, ATTR_RY };
   nsSVGLength2 mLengthAttributes[6];
   static LengthInfo sLengthInfo[6];
 };
--- a/dom/svg/SVGSVGElement.cpp
+++ b/dom/svg/SVGSVGElement.cpp
@@ -137,29 +137,29 @@ SVGSVGElement::~SVGSVGElement() {}
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT_AND_PARSER(SVGSVGElement)
 
 //----------------------------------------------------------------------
 // nsIDOMSVGSVGElement methods:
 
-already_AddRefed<SVGAnimatedLength> SVGSVGElement::X() {
+already_AddRefed<DOMSVGAnimatedLength> SVGSVGElement::X() {
   return mLengthAttributes[ATTR_X].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGSVGElement::Y() {
+already_AddRefed<DOMSVGAnimatedLength> SVGSVGElement::Y() {
   return mLengthAttributes[ATTR_Y].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGSVGElement::Width() {
+already_AddRefed<DOMSVGAnimatedLength> SVGSVGElement::Width() {
   return mLengthAttributes[ATTR_WIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGSVGElement::Height() {
+already_AddRefed<DOMSVGAnimatedLength> SVGSVGElement::Height() {
   return mLengthAttributes[ATTR_HEIGHT].ToDOMAnimatedLength(this);
 }
 
 bool SVGSVGElement::UseCurrentView() { return mSVGView || mCurrentViewID; }
 
 float SVGSVGElement::CurrentScale() { return mCurrentScale; }
 
 #define CURRENT_SCALE_MAX 16.0f
--- a/dom/svg/SVGSVGElement.h
+++ b/dom/svg/SVGSVGElement.h
@@ -107,20 +107,20 @@ class SVGSVGElement final : public SVGSV
   // nsIContent interface
   void GetEventTargetParent(EventChainPreVisitor& aVisitor) override;
   virtual bool IsEventAttributeNameInternal(nsAtom* aName) override;
 
   // nsINode methods:
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> X();
-  already_AddRefed<SVGAnimatedLength> Y();
-  already_AddRefed<SVGAnimatedLength> Width();
-  already_AddRefed<SVGAnimatedLength> Height();
+  already_AddRefed<DOMSVGAnimatedLength> X();
+  already_AddRefed<DOMSVGAnimatedLength> Y();
+  already_AddRefed<DOMSVGAnimatedLength> Width();
+  already_AddRefed<DOMSVGAnimatedLength> Height();
   bool UseCurrentView();
   float CurrentScale();
   void SetCurrentScale(float aCurrentScale);
   already_AddRefed<nsISVGPoint> CurrentTranslate();
   void SetCurrentTranslate(float x, float y);
   uint32_t SuspendRedraw(uint32_t max_wait_milliseconds);
   void UnsuspendRedraw(uint32_t suspend_handle_id);
   void UnsuspendRedrawAll();
--- a/dom/svg/SVGScriptElement.cpp
+++ b/dom/svg/SVGScriptElement.cpp
@@ -85,17 +85,17 @@ void SVGScriptElement::GetCrossOrigin(ns
   GetEnumAttr(nsGkAtoms::crossorigin, nullptr, aCrossOrigin);
 }
 
 void SVGScriptElement::SetCrossOrigin(const nsAString& aCrossOrigin,
                                       ErrorResult& aError) {
   SetOrRemoveNullableStringAttr(nsGkAtoms::crossorigin, aCrossOrigin, aError);
 }
 
-already_AddRefed<SVGAnimatedString> SVGScriptElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGScriptElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 // nsIScriptElement methods
 
--- a/dom/svg/SVGScriptElement.h
+++ b/dom/svg/SVGScriptElement.h
@@ -64,17 +64,17 @@ class SVGScriptElement final : public SV
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
   void GetType(nsAString& aType);
   void SetType(const nsAString& aType, ErrorResult& rv);
   void GetCrossOrigin(nsAString& aCrossOrigin);
   void SetCrossOrigin(const nsAString& aCrossOrigin, ErrorResult& aError);
-  already_AddRefed<SVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedString> Href();
 
  protected:
   ~SVGScriptElement();
 
   virtual StringAttributesInfo GetStringInfo() override;
 
   // SVG Script elements don't have the ability to set async properties on
   // themselves, so this will always return false.
--- a/dom/svg/SVGStopElement.cpp
+++ b/dom/svg/SVGStopElement.cpp
@@ -29,17 +29,17 @@ SVGStopElement::SVGStopElement(
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGStopElement)
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedNumber> SVGStopElement::Offset() {
+already_AddRefed<DOMSVGAnimatedNumber> SVGStopElement::Offset() {
   return mOffset.ToDOMAnimatedNumber(this);
 }
 
 //----------------------------------------------------------------------
 // sSVGElement methods
 
 SVGElement::NumberAttributesInfo SVGStopElement::GetNumberInfo() {
   return NumberAttributesInfo(&mOffset, &sNumberInfo, 1);
--- a/dom/svg/SVGStopElement.h
+++ b/dom/svg/SVGStopElement.h
@@ -29,17 +29,17 @@ class SVGStopElement final : public SVGS
 
  public:
   // nsIContent interface
   NS_IMETHOD_(bool) IsAttributeMapped(const nsAtom* aAttribute) const override;
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedNumber> Offset();
+  already_AddRefed<DOMSVGAnimatedNumber> Offset();
 
  protected:
   virtual NumberAttributesInfo GetNumberInfo() override;
   nsSVGNumber2 mOffset;
   static NumberInfo sNumberInfo;
 };
 
 }  // namespace dom
--- a/dom/svg/SVGString.cpp
+++ b/dom/svg/SVGString.cpp
@@ -68,17 +68,17 @@ void SVGString::SetAnimValue(const nsASt
     if (!mAnimVal) {
       mAnimVal = new nsString();
     }
     *mAnimVal = aValue;
     aSVGElement->DidAnimateString(mAttrEnum);
   }
 }
 
-already_AddRefed<SVGAnimatedString> SVGString::ToDOMAnimatedString(
+already_AddRefed<DOMSVGAnimatedString> SVGString::ToDOMAnimatedString(
     SVGElement* aSVGElement) {
   RefPtr<DOMAnimatedString> domAnimatedString =
       SVGAnimatedStringTearoffTable().GetTearoff(this);
   if (!domAnimatedString) {
     domAnimatedString = new DOMAnimatedString(this, aSVGElement);
     SVGAnimatedStringTearoffTable().AddTearoff(this, domAnimatedString);
   }
 
--- a/dom/svg/SVGString.h
+++ b/dom/svg/SVGString.h
@@ -2,19 +2,19 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef __NS_SVGSTRING_H__
 #define __NS_SVGSTRING_H__
 
+#include "DOMSVGAnimatedString.h"
 #include "nsAutoPtr.h"
 #include "nsError.h"
-#include "mozilla/dom/SVGAnimatedString.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/UniquePtr.h"
 
 namespace mozilla {
 
 class SMILValue;
 
 namespace dom {
@@ -42,33 +42,35 @@ class SVGString {
 
   // Returns true if the animated value of this string has been explicitly
   // set (either by animation, or by taking on the base value which has been
   // explicitly set by markup or a DOM call), false otherwise.
   // If this returns false, the animated value is still valid, that is,
   // usable, and represents the default base value of the attribute.
   bool IsExplicitlySet() const { return !!mAnimVal || mIsBaseSet; }
 
-  already_AddRefed<mozilla::dom::SVGAnimatedString> ToDOMAnimatedString(
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedString> ToDOMAnimatedString(
       SVGElement* aSVGElement);
 
   mozilla::UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
  private:
   nsAutoPtr<nsString> mAnimVal;
   uint8_t mAttrEnum;  // element specified tracking for attribute
   bool mIsBaseSet;
 
  public:
-  struct DOMAnimatedString final : public mozilla::dom::SVGAnimatedString {
+  // DOM wrapper class for the (DOM)SVGAnimatedString interface where the
+  // wrapped class is SVGString.
+  struct DOMAnimatedString final : public mozilla::dom::DOMSVGAnimatedString {
     NS_DECL_CYCLE_COLLECTING_ISUPPORTS
     NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(DOMAnimatedString)
 
     DOMAnimatedString(SVGString* aVal, SVGElement* aSVGElement)
-        : mozilla::dom::SVGAnimatedString(aSVGElement), mVal(aVal) {}
+        : mozilla::dom::DOMSVGAnimatedString(aSVGElement), mVal(aVal) {}
 
     SVGString* mVal;  // kept alive because it belongs to content
 
     void GetBaseVal(nsAString& aResult) override {
       mVal->GetBaseValue(aResult, mSVGElement);
     }
 
     void SetBaseVal(const nsAString& aValue) override {
--- a/dom/svg/SVGStringList.h
+++ b/dom/svg/SVGStringList.h
@@ -58,17 +58,17 @@ class SVGStringList {
   // Returns true if the value of this stringlist has been explicitly
   // set by markup or a DOM call, false otherwise.
   bool IsExplicitlySet() const { return mIsSet; }
 
   // Access to methods that can modify objects of this type is deliberately
   // limited. This is to reduce the chances of someone modifying objects of
   // this type without taking the necessary steps to keep DOM wrappers in sync.
   // If you need wider access to these methods, consider adding a method to
-  // SVGAnimatedStringList and having that class act as an intermediary so it
+  // DOMSVGAnimatedStringList and having that class act as an intermediary so it
   // can take care of keeping DOM wrappers in sync.
 
  protected:
   /**
    * This may fail on OOM if the internal capacity needs to be increased, in
    * which case the list will be left unmodified.
    */
   nsresult CopyFrom(const SVGStringList& rhs);
--- a/dom/svg/SVGTextContentElement.cpp
+++ b/dom/svg/SVGTextContentElement.cpp
@@ -43,21 +43,22 @@ SVGTextFrame* SVGTextContentElement::Get
 SVGTextFrame*
 SVGTextContentElement::GetSVGTextFrameForNonLayoutDependentQuery() {
   nsIFrame* frame = GetPrimaryFrame(FlushType::Frames);
   nsIFrame* textFrame =
       nsLayoutUtils::GetClosestFrameOfType(frame, LayoutFrameType::SVGText);
   return static_cast<SVGTextFrame*>(textFrame);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGTextContentElement::TextLength() {
+already_AddRefed<DOMSVGAnimatedLength> SVGTextContentElement::TextLength() {
   return LengthAttributes()[TEXTLENGTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGTextContentElement::LengthAdjust() {
+already_AddRefed<DOMSVGAnimatedEnumeration>
+SVGTextContentElement::LengthAdjust() {
   return EnumAttributes()[LENGTHADJUST].ToDOMAnimatedEnum(this);
 }
 
 //----------------------------------------------------------------------
 
 template <typename T>
 static bool FragmentHasSkippableCharacter(const T* aBuffer, uint32_t aLength) {
   for (uint32_t i = 0; i < aLength; i++) {
--- a/dom/svg/SVGTextContentElement.h
+++ b/dom/svg/SVGTextContentElement.h
@@ -3,17 +3,17 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef mozilla_dom_SVGTextContentElement_h
 #define mozilla_dom_SVGTextContentElement_h
 
 #include "mozilla/dom/SVGGraphicsElement.h"
-#include "mozilla/dom/SVGAnimatedEnumeration.h"
+#include "DOMSVGAnimatedEnumeration.h"
 #include "SVGEnum.h"
 #include "nsSVGLength2.h"
 
 class SVGTextFrame;
 
 namespace mozilla {
 class nsISVGPoint;
 
@@ -25,18 +25,18 @@ typedef SVGGraphicsElement SVGTextConten
 
 class SVGTextContentElement : public SVGTextContentElementBase {
   friend class ::SVGTextFrame;
 
  public:
   using FragmentOrElement::TextLength;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> TextLength();
-  already_AddRefed<SVGAnimatedEnumeration> LengthAdjust();
+  already_AddRefed<DOMSVGAnimatedLength> TextLength();
+  already_AddRefed<DOMSVGAnimatedEnumeration> LengthAdjust();
   MOZ_CAN_RUN_SCRIPT int32_t GetNumberOfChars();
   MOZ_CAN_RUN_SCRIPT float GetComputedTextLength();
   MOZ_CAN_RUN_SCRIPT
   void SelectSubString(uint32_t charnum, uint32_t nchars, ErrorResult& rv);
   MOZ_CAN_RUN_SCRIPT
   float GetSubStringLength(uint32_t charnum, uint32_t nchars, ErrorResult& rv);
   MOZ_CAN_RUN_SCRIPT
   already_AddRefed<nsISVGPoint> GetStartPositionOfChar(uint32_t charnum,
--- a/dom/svg/SVGTextPathElement.cpp
+++ b/dom/svg/SVGTextPathElement.cpp
@@ -15,17 +15,17 @@
 NS_IMPL_NS_NEW_SVG_ELEMENT(TextPath)
 
 namespace mozilla {
 namespace dom {
 
 using namespace SVGTextContentElement_Binding;
 using namespace SVGTextPathElement_Binding;
 
-class SVGAnimatedLength;
+class DOMSVGAnimatedLength;
 
 JSObject* SVGTextPathElement::WrapNode(JSContext* aCx,
                                        JS::Handle<JSObject*> aGivenProto) {
   return SVGTextPathElement_Binding::Wrap(aCx, this, aGivenProto);
 }
 
 SVGElement::LengthInfo SVGTextPathElement::sLengthInfo[2] = {
     // from SVGTextContentElement:
@@ -77,37 +77,37 @@ void SVGTextPathElement::HrefAsString(ns
   }
 }
 
 //----------------------------------------------------------------------
 // nsINode methods
 
 NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGTextPathElement)
 
-already_AddRefed<SVGAnimatedString> SVGTextPathElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGTextPathElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGTextPathElement::StartOffset() {
+already_AddRefed<DOMSVGAnimatedLength> SVGTextPathElement::StartOffset() {
   return mLengthAttributes[STARTOFFSET].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGTextPathElement::Method() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGTextPathElement::Method() {
   return mEnumAttributes[METHOD].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGTextPathElement::Spacing() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGTextPathElement::Spacing() {
   return mEnumAttributes[SPACING].ToDOMAnimatedEnum(this);
 }
 
-already_AddRefed<SVGAnimatedEnumeration> SVGTextPathElement::Side() {
+already_AddRefed<DOMSVGAnimatedEnumeration> SVGTextPathElement::Side() {
   return mEnumAttributes[SIDE].ToDOMAnimatedEnum(this);
 }
 
 //----------------------------------------------------------------------
 // nsIContent methods
 
 NS_IMETHODIMP_(bool)
 SVGTextPathElement::IsAttributeMapped(const nsAtom* name) const {
--- a/dom/svg/SVGTextPathElement.h
+++ b/dom/svg/SVGTextPathElement.h
@@ -46,21 +46,21 @@ class SVGTextPathElement final : public 
 
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
 
   SVGAnimatedPathSegList* GetAnimPathSegList() override { return &mPath; }
 
   nsStaticAtom* GetPathDataAttrName() const override { return nsGkAtoms::path; }
 
   // WebIDL
-  already_AddRefed<SVGAnimatedLength> StartOffset();
-  already_AddRefed<SVGAnimatedEnumeration> Method();
-  already_AddRefed<SVGAnimatedEnumeration> Spacing();
-  already_AddRefed<SVGAnimatedEnumeration> Side();
-  already_AddRefed<SVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedLength> StartOffset();
+  already_AddRefed<DOMSVGAnimatedEnumeration> Method();
+  already_AddRefed<DOMSVGAnimatedEnumeration> Spacing();
+  already_AddRefed<DOMSVGAnimatedEnumeration> Side();
+  already_AddRefed<DOMSVGAnimatedString> Href();
 
   void HrefAsString(nsAString& aHref);
 
  protected:
   virtual LengthAttributesInfo GetLengthInfo() override;
   virtual EnumAttributesInfo GetEnumInfo() override;
   virtual StringAttributesInfo GetStringInfo() override;
 
--- a/dom/svg/SVGUseElement.cpp
+++ b/dom/svg/SVGUseElement.cpp
@@ -160,37 +160,37 @@ nsresult SVGUseElement::BindToTree(Docum
   return NS_OK;
 }
 
 void SVGUseElement::UnbindFromTree(bool aDeep, bool aNullParent) {
   SVGUseElementBase::UnbindFromTree(aDeep, aNullParent);
   OwnerDoc()->UnscheduleSVGUseElementShadowTreeUpdate(*this);
 }
 
-already_AddRefed<SVGAnimatedString> SVGUseElement::Href() {
+already_AddRefed<DOMSVGAnimatedString> SVGUseElement::Href() {
   return mStringAttributes[HREF].IsExplicitlySet()
              ? mStringAttributes[HREF].ToDOMAnimatedString(this)
              : mStringAttributes[XLINK_HREF].ToDOMAnimatedString(this);
 }
 
 //----------------------------------------------------------------------
 
-already_AddRefed<SVGAnimatedLength> SVGUseElement::X() {
+already_AddRefed<DOMSVGAnimatedLength> SVGUseElement::X() {
   return mLengthAttributes[ATTR_X].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGUseElement::Y() {
+already_AddRefed<DOMSVGAnimatedLength> SVGUseElement::Y() {
   return mLengthAttributes[ATTR_Y].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGUseElement::Width() {
+already_AddRefed<DOMSVGAnimatedLength> SVGUseElement::Width() {
   return mLengthAttributes[ATTR_WIDTH].ToDOMAnimatedLength(this);
 }
 
-already_AddRefed<SVGAnimatedLength> SVGUseElement::Height() {
+already_AddRefed<DOMSVGAnimatedLength> SVGUseElement::Height() {
   return mLengthAttributes[ATTR_HEIGHT].ToDOMAnimatedLength(this);
 }
 
 //----------------------------------------------------------------------
 // nsIMutationObserver methods
 
 void SVGUseElement::CharacterDataChanged(nsIContent* aContent,
                                          const CharacterDataChangeInfo&) {
--- a/dom/svg/SVGUseElement.h
+++ b/dom/svg/SVGUseElement.h
@@ -70,21 +70,21 @@ class SVGUseElement final : public SVGUs
       SVGTransformTypes aWhich = eAllTransforms) const override;
   virtual bool HasValidDimensions() const override;
 
   // nsIContent interface
   virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
   NS_IMETHOD_(bool) IsAttributeMapped(const nsAtom* aAttribute) const override;
 
   // WebIDL
-  already_AddRefed<SVGAnimatedString> Href();
-  already_AddRefed<SVGAnimatedLength> X();
-  already_AddRefed<SVGAnimatedLength> Y();
-  already_AddRefed<SVGAnimatedLength> Width();
-  already_AddRefed<SVGAnimatedLength> Height();
+  already_AddRefed<DOMSVGAnimatedString> Href();
+  already_AddRefed<DOMSVGAnimatedLength> X();
+  already_AddRefed<DOMSVGAnimatedLength> Y();
+  already_AddRefed<DOMSVGAnimatedLength> Width();
+  already_AddRefed<DOMSVGAnimatedLength> Height();
 
   nsIURI* GetSourceDocURI();
   URLExtraData* GetContentURLData() const { return mContentURLData; }
 
   // Updates the internal shadow tree to be an up-to-date clone of the
   // referenced element.
   void UpdateShadowTree();
 
--- a/dom/svg/SVGViewBox.cpp
+++ b/dom/svg/SVGViewBox.cpp
@@ -8,16 +8,18 @@
 
 #include "mozilla/Move.h"
 #include "mozilla/SMILValue.h"
 #include "mozilla/SVGContentUtils.h"
 #include "nsCharSeparatedTokenizer.h"
 #include "SVGViewBoxSMILType.h"
 #include "nsTextFormatter.h"
 
+using namespace mozilla::dom;
+
 namespace mozilla {
 
 #define NUM_VIEWBOX_COMPONENTS 4
 
 /* Implementation of SVGViewBoxRect methods */
 
 bool SVGViewBoxRect::operator==(const SVGViewBoxRect& aOther) const {
   if (&aOther == this) return true;
@@ -82,17 +84,17 @@ NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
   NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
 static SVGAttrTearoffTable<SVGViewBox, SVGViewBox::DOMBaseVal>
     sBaseSVGViewBoxTearoffTable;
 static SVGAttrTearoffTable<SVGViewBox, SVGViewBox::DOMAnimVal>
     sAnimSVGViewBoxTearoffTable;
-SVGAttrTearoffTable<SVGViewBox, dom::SVGAnimatedRect>
+SVGAttrTearoffTable<SVGViewBox, SVGAnimatedRect>
     SVGViewBox::sSVGAnimatedRectTearoffTable;
 
 /* Implementation of SVGViewBox methods */
 
 void SVGViewBox::Init() {
   mHasBaseVal = false;
   // We shouldn't use mBaseVal for rendering (its usages should be guarded with
   // "mHasBaseVal" checks), but just in case we do by accident, this will
@@ -188,29 +190,29 @@ void SVGViewBox::GetBaseValueString(nsAS
     aValue.AssignLiteral("none");
     return;
   }
   nsTextFormatter::ssprintf(aValue, u"%g %g %g %g", (double)mBaseVal.x,
                             (double)mBaseVal.y, (double)mBaseVal.width,
                             (double)mBaseVal.height);
 }
 
-already_AddRefed<dom::SVGAnimatedRect> SVGViewBox::ToSVGAnimatedRect(
+already_AddRefed<SVGAnimatedRect> SVGViewBox::ToSVGAnimatedRect(
     SVGElement* aSVGElement) {
-  RefPtr<dom::SVGAnimatedRect> domAnimatedRect =
+  RefPtr<SVGAnimatedRect> domAnimatedRect =
       sSVGAnimatedRectTearoffTable.GetTearoff(this);
   if (!domAnimatedRect) {
-    domAnimatedRect = new dom::SVGAnimatedRect(this, aSVGElement);
+    domAnimatedRect = new SVGAnimatedRect(this, aSVGElement);
     sSVGAnimatedRectTearoffTable.AddTearoff(this, domAnimatedRect);
   }
 
   return domAnimatedRect.forget();
 }
 
-already_AddRefed<dom::SVGIRect> SVGViewBox::ToDOMBaseVal(
+already_AddRefed<SVGIRect> SVGViewBox::ToDOMBaseVal(
     SVGElement* aSVGElement) {
   if (!mHasBaseVal || mBaseVal.none) {
     return nullptr;
   }
 
   RefPtr<DOMBaseVal> domBaseVal = sBaseSVGViewBoxTearoffTable.GetTearoff(this);
   if (!domBaseVal) {
     domBaseVal = new DOMBaseVal(this, aSVGElement);
@@ -219,17 +221,17 @@ already_AddRefed<dom::SVGIRect> SVGViewB
 
   return domBaseVal.forget();
 }
 
 SVGViewBox::DOMBaseVal::~DOMBaseVal() {
   sBaseSVGViewBoxTearoffTable.RemoveTearoff(mVal);
 }
 
-already_AddRefed<dom::SVGIRect> SVGViewBox::ToDOMAnimVal(
+already_AddRefed<SVGIRect> SVGViewBox::ToDOMAnimVal(
     SVGElement* aSVGElement) {
   if ((mAnimVal && mAnimVal->none) ||
       (!mAnimVal && (!mHasBaseVal || mBaseVal.none))) {
     return nullptr;
   }
 
   RefPtr<DOMAnimVal> domAnimVal = sAnimSVGViewBoxTearoffTable.GetTearoff(this);
   if (!domAnimVal) {
@@ -268,17 +270,17 @@ void SVGViewBox::DOMBaseVal::SetHeight(f
   mVal->SetBaseValue(rect, mSVGElement);
 }
 
 UniquePtr<SMILAttr> SVGViewBox::ToSMILAttr(SVGElement* aSVGElement) {
   return MakeUnique<SMILViewBox>(this, aSVGElement);
 }
 
 nsresult SVGViewBox::SMILViewBox ::ValueFromString(
-    const nsAString& aStr, const dom::SVGAnimationElement* /*aSrcElement*/,
+    const nsAString& aStr, const SVGAnimationElement* /*aSrcElement*/,
     SMILValue& aValue, bool& aPreventCachingOfSandwich) const {
   SVGViewBoxRect viewBox;
   nsresult res = SVGViewBoxRect::FromString(aStr, &viewBox);
   if (NS_FAILED(res)) {
     return res;
   }
   SMILValue val(&SVGViewBoxSMILType::sSingleton);
   *static_cast<SVGViewBoxRect*>(val.mU.mPtr) = viewBox;
--- a/dom/svg/moz.build
+++ b/dom/svg/moz.build
@@ -13,28 +13,19 @@ EXPORTS.mozilla += [
     'SVGAttrValueWrapper.h',
     'SVGContentUtils.h',
     'SVGPreserveAspectRatio.h',
     'SVGStringList.h',
     'SVGTagList.h',
 ]
 
 EXPORTS.mozilla.dom += [
-    'DOMSVGAngle.h',
-    'DOMSVGTransform.h',
     'SVGAElement.h',
-    'SVGAnimatedAngle.h',
-    'SVGAnimatedBoolean.h',
-    'SVGAnimatedEnumeration.h',
-    'SVGAnimatedInteger.h',
-    'SVGAnimatedLength.h',
-    'SVGAnimatedNumber.h',
     'SVGAnimatedPathSegList.h',
     'SVGAnimatedRect.h',
-    'SVGAnimatedString.h',
     'SVGAnimateElement.h',
     'SVGAnimateMotionElement.h',
     'SVGAnimateTransformElement.h',
     'SVGAnimationElement.h',
     'SVGCircleElement.h',
     'SVGClass.h',
     'SVGClipPathElement.h',
     'SVGComponentTransferFunctionElement.h',
@@ -103,47 +94,47 @@ EXPORTS.mozilla.dom += [
     'SVGTSpanElement.h',
     'SVGUseElement.h',
     'SVGViewElement.h',
     'SVGViewportElement.h',
 ]
 
 UNIFIED_SOURCES += [
     'DOMSVGAngle.cpp',
+    'DOMSVGAnimatedAngle.cpp',
+    'DOMSVGAnimatedBoolean.cpp',
+    'DOMSVGAnimatedEnumeration.cpp',
+    'DOMSVGAnimatedInteger.cpp',
+    'DOMSVGAnimatedLength.cpp',
     'DOMSVGAnimatedLengthList.cpp',
+    'DOMSVGAnimatedNumber.cpp',
     'DOMSVGAnimatedNumberList.cpp',
+    'DOMSVGAnimatedString.cpp',
     'DOMSVGAnimatedTransformList.cpp',
     'DOMSVGLength.cpp',
     'DOMSVGLengthList.cpp',
     'DOMSVGNumber.cpp',
     'DOMSVGNumberList.cpp',
     'DOMSVGPathSeg.cpp',
     'DOMSVGPathSegList.cpp',
     'DOMSVGPoint.cpp',
     'DOMSVGPointList.cpp',
     'DOMSVGStringList.cpp',
     'DOMSVGTransform.cpp',
     'DOMSVGTransformList.cpp',
     'nsISVGPoint.cpp',
     'nsSVGLength2.cpp',
     'nsSVGNumber2.cpp',
     'SVGAElement.cpp',
-    'SVGAnimatedAngle.cpp',
-    'SVGAnimatedBoolean.cpp',
-    'SVGAnimatedEnumeration.cpp',
-    'SVGAnimatedInteger.cpp',
-    'SVGAnimatedLength.cpp',
     'SVGAnimatedLengthList.cpp',
-    'SVGAnimatedNumber.cpp',
     'SVGAnimatedNumberList.cpp',
     'SVGAnimatedPathSegList.cpp',
     'SVGAnimatedPointList.cpp',
     'SVGAnimatedPreserveAspectRatio.cpp',
     'SVGAnimatedRect.cpp',
-    'SVGAnimatedString.cpp',
     'SVGAnimatedTransformList.cpp',
     'SVGAnimateElement.cpp',
     'SVGAnimateMotionElement.cpp',
     'SVGAnimateTransformElement.cpp',
     'SVGAnimationElement.cpp',
     'SVGAttrValueWrapper.cpp',
     'SVGBoolean.cpp',
     'SVGCircleElement.cpp',
--- a/dom/svg/nsSVGLength2.cpp
+++ b/dom/svg/nsSVGLength2.cpp
@@ -3,26 +3,26 @@
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #include "nsSVGLength2.h"
 
 #include "mozilla/ArrayUtils.h"
 #include "mozilla/SMILValue.h"
-#include "mozilla/dom/SVGAnimatedLength.h"
 #include "mozilla/dom/SVGViewportElement.h"
+#include "DOMSVGAnimatedLength.h"
+#include "DOMSVGLength.h"
+#include "LayoutLogging.h"
 #include "nsContentUtils.h"
-#include "DOMSVGLength.h"
 #include "nsIFrame.h"
-#include "LayoutLogging.h"
+#include "nsTextFormatter.h"
 #include "SMILFloatType.h"
 #include "SVGAttrTearoffTable.h"
 #include "nsSVGIntegrationUtils.h"
-#include "nsTextFormatter.h"
 
 using namespace mozilla;
 using namespace mozilla::dom;
 
 static const nsStaticAtom* const unitMap[] = {
     nullptr, /* SVG_LENGTHTYPE_UNKNOWN */
     nullptr, /* SVG_LENGTHTYPE_NUMBER */
     nsGkAtoms::percentage,
@@ -30,17 +30,17 @@ static const nsStaticAtom* const unitMap
     nsGkAtoms::ex,
     nsGkAtoms::px,
     nsGkAtoms::cm,
     nsGkAtoms::mm,
     nsGkAtoms::in,
     nsGkAtoms::pt,
     nsGkAtoms::pc};
 
-static SVGAttrTearoffTable<nsSVGLength2, SVGAnimatedLength>
+static SVGAttrTearoffTable<nsSVGLength2, DOMSVGAnimatedLength>
     sSVGAnimatedLengthTearoffTable;
 
 /* Helper functions */
 
 static bool IsValidUnitType(uint16_t unit) {
   if (unit > SVGLength_Binding::SVG_LENGTHTYPE_UNKNOWN &&
       unit <= SVGLength_Binding::SVG_LENGTHTYPE_PC)
     return true;
@@ -393,29 +393,29 @@ nsresult nsSVGLength2::SetAnimValue(floa
 
   if (IsFinite(valueInSpecifiedUnits)) {
     SetAnimValueInSpecifiedUnits(valueInSpecifiedUnits, aSVGElement);
     return NS_OK;
   }
   return NS_ERROR_ILLEGAL_VALUE;
 }
 
-already_AddRefed<SVGAnimatedLength> nsSVGLength2::ToDOMAnimatedLength(
+already_AddRefed<DOMSVGAnimatedLength> nsSVGLength2::ToDOMAnimatedLength(
     SVGElement* aSVGElement) {
-  RefPtr<SVGAnimatedLength> svgAnimatedLength =
+  RefPtr<DOMSVGAnimatedLength> svgAnimatedLength =
       sSVGAnimatedLengthTearoffTable.GetTearoff(this);
   if (!svgAnimatedLength) {
-    svgAnimatedLength = new SVGAnimatedLength(this, aSVGElement);
+    svgAnimatedLength = new DOMSVGAnimatedLength(this, aSVGElement);
     sSVGAnimatedLengthTearoffTable.AddTearoff(this, svgAnimatedLength);
   }
 
   return svgAnimatedLength.forget();
 }
 
-SVGAnimatedLength::~SVGAnimatedLength() {
+DOMSVGAnimatedLength::~DOMSVGAnimatedLength() {
   sSVGAnimatedLengthTearoffTable.RemoveTearoff(mVal);
 }
 
 UniquePtr<SMILAttr> nsSVGLength2::ToSMILAttr(SVGElement* aSVGElement) {
   return MakeUnique<SMILLength>(this, aSVGElement);
 }
 
 nsresult nsSVGLength2::SMILLength::ValueFromString(
--- a/dom/svg/nsSVGLength2.h
+++ b/dom/svg/nsSVGLength2.h
@@ -21,18 +21,18 @@
 
 class nsIFrame;
 
 namespace mozilla {
 
 class SMILValue;
 
 namespace dom {
+class DOMSVGAnimatedLength;
 class DOMSVGLength;
-class SVGAnimatedLength;
 class SVGAnimationElement;
 class SVGViewportElement;
 }  // namespace dom
 }  // namespace mozilla
 
 namespace mozilla {
 namespace dom {
 
@@ -81,17 +81,17 @@ class NonSVGFrameUserSpaceMetrics : publ
  private:
   nsIFrame* mFrame;
 };
 
 }  // namespace dom
 }  // namespace mozilla
 
 class nsSVGLength2 {
-  friend class mozilla::dom::SVGAnimatedLength;
+  friend class mozilla::dom::DOMSVGAnimatedLength;
   friend class mozilla::dom::DOMSVGLength;
   typedef mozilla::dom::DOMSVGLength DOMSVGLength;
   typedef mozilla::dom::SVGElement SVGElement;
   typedef mozilla::dom::SVGViewportElement SVGViewportElement;
   typedef mozilla::dom::UserSpaceMetrics UserSpaceMetrics;
   typedef mozilla::SMILAttr SMILAttr;
   typedef mozilla::SMILValue SMILValue;
   typedef mozilla::SVGContentUtils SVGContentUtils;
@@ -156,17 +156,17 @@ class nsSVGLength2 {
   bool HasBaseVal() const { return mIsBaseSet; }
   // Returns true if the animated value of this length has been explicitly
   // set (either by animation, or by taking on the base value which has been
   // explicitly set by markup or a DOM call), false otherwise.
   // If this returns false, the animated value is still valid, that is,
   // usable, and represents the default base value of the attribute.
   bool IsExplicitlySet() const { return mIsAnimated || mIsBaseSet; }
 
-  already_AddRefed<mozilla::dom::SVGAnimatedLength> ToDOMAnimatedLength(
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedLength> ToDOMAnimatedLength(
       SVGElement* aSVGElement);
 
   mozilla::UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
  private:
   float mAnimVal;
   float mBaseVal;
   uint8_t mSpecifiedUnitType;
--- a/dom/svg/nsSVGNumber2.cpp
+++ b/dom/svg/nsSVGNumber2.cpp
@@ -90,17 +90,17 @@ void nsSVGNumber2::SetAnimValue(float aV
   if (mIsAnimated && aValue == mAnimVal) {
     return;
   }
   mAnimVal = aValue;
   mIsAnimated = true;
   aSVGElement->DidAnimateNumber(mAttrEnum);
 }
 
-already_AddRefed<SVGAnimatedNumber> nsSVGNumber2::ToDOMAnimatedNumber(
+already_AddRefed<DOMSVGAnimatedNumber> nsSVGNumber2::ToDOMAnimatedNumber(
     SVGElement* aSVGElement) {
   RefPtr<DOMAnimatedNumber> domAnimatedNumber =
       sSVGAnimatedNumberTearoffTable.GetTearoff(this);
   if (!domAnimatedNumber) {
     domAnimatedNumber = new DOMAnimatedNumber(this, aSVGElement);
     sSVGAnimatedNumberTearoffTable.AddTearoff(this, domAnimatedNumber);
   }
 
--- a/dom/svg/nsSVGNumber2.h
+++ b/dom/svg/nsSVGNumber2.h
@@ -2,24 +2,24 @@
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * 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/. */
 
 #ifndef __NS_SVGNUMBER2_H__
 #define __NS_SVGNUMBER2_H__
 
+#include "DOMSVGAnimatedNumber.h"
 #include "nsCycleCollectionParticipant.h"
 #include "nsError.h"
 #include "nsMathUtils.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/FloatingPoint.h"
 #include "mozilla/SMILAttr.h"
 #include "mozilla/UniquePtr.h"
-#include "mozilla/dom/SVGAnimatedNumber.h"
 #include "mozilla/dom/SVGElement.h"
 
 namespace mozilla {
 
 class SMILValue;
 
 namespace dom {
 class SVGAnimationElement;
@@ -49,31 +49,33 @@ class nsSVGNumber2 {
 
   // Returns true if the animated value of this number has been explicitly
   // set (either by animation, or by taking on the base value which has been
   // explicitly set by markup or a DOM call), false otherwise.
   // If this returns false, the animated value is still valid, that is,
   // usable, and represents the default base value of the attribute.
   bool IsExplicitlySet() const { return mIsAnimated || mIsBaseSet; }
 
-  already_AddRefed<mozilla::dom::SVGAnimatedNumber> ToDOMAnimatedNumber(
+  already_AddRefed<mozilla::dom::DOMSVGAnimatedNumber> ToDOMAnimatedNumber(
       SVGElement* aSVGElement);
   mozilla::UniquePtr<SMILAttr> ToSMILAttr(SVGElement* aSVGElement);
 
  private:
   float mAnimVal;
   float mBaseVal;
   uint8_t mAttrEnum;  // element specified tracking for attribute
   bool mIsAnimated;
   bool mIsBaseSet;
 
  public:
-  struct DOMAnimatedNumber final : public mozilla::dom::SVGAnimatedNumber {
+  // DOM wrapper class for the (DOM)SVGAnimatedNumber interface where the
+  // wrapped class is nsSVGNumber2.
+  struct DOMAnimatedNumber final : public mozilla::dom::DOMSVGAnimatedNumber {
     DOMAnimatedNumber(nsSVGNumber2* aVal, SVGElement* aSVGElement)
-        : mozilla::dom::SVGAnimatedNumber(aSVGElement), mVal(aVal) {}
+        : mozilla::dom::DOMSVGAnimatedNumber(aSVGElement), mVal(aVal) {}
     virtual ~DOMAnimatedNumber();
 
     nsSVGNumber2* mVal;  // kept alive because it belongs to content
 
     virtual float BaseVal() override { return mVal->GetBaseValue(); }
     virtual void SetBaseVal(float aValue) override {
       MOZ_ASSERT(mozilla::IsFinite(aValue));
       mVal->SetBaseValue(aValue, mSVGElement);
--- a/gfx/2d/Tools.h
+++ b/gfx/2d/Tools.h
@@ -120,17 +120,17 @@ struct AlignedArray {
       mCount = 0;
       return;
     }
     // We don't create an array of T here, since we don't want ctors to be
     // invoked at the wrong places if we realign below.
     if (aZero) {
       // calloc can be more efficient than new[] for large chunks,
       // so we use calloc/malloc/free for everything.
-      mStorage = static_cast<uint8_t *>(calloc(1, storageByteCount.value()));
+      mStorage = static_cast<uint8_t *>(calloc(1u, storageByteCount.value()));
     } else {
       mStorage = static_cast<uint8_t *>(malloc(storageByteCount.value()));
     }
     if (!mStorage) {
       mStorage = nullptr;
       mPtr = nullptr;
       mCount = 0;
       return;
--- a/testing/geckodriver/doc/TraceLogs.md
+++ b/testing/geckodriver/doc/TraceLogs.md
@@ -66,17 +66,17 @@ The log level is set in different ways. 
 `--log <LEVEL>` option, where `LEVEL` is one of the log levels
 from the list above, or by using the `-v` (for debug) or `-vv`
 (for trace) shorthands.  For example, the following command will
 enable trace logs for both geckodriver and Marionette:
 
 	% geckodriver -vv
 
 The second way of setting the log level is through capabilities.
-geckodriver accepts a Mozila-specific configuration object
+geckodriver accepts a Mozilla-specific configuration object
 in [`moz:firefoxOptions`].  This JSON Object, which is further
 described in the [README] can hold Firefox-specific configuration,
 such as which Firefox binary to use, additional preferences to set,
 and of course which log level to use.
 
 [`moz:firefoxOptions`]: https://searchfox.org/mozilla-central/source/testing/geckodriver/README.md#firefox-capabilities
 [README]: https://searchfox.org/mozilla-central/source/testing/geckodriver/README.md