Merge mozilla-inbound to mozilla-central. a=merge

This commit is contained in:
Daniel Varga 2019-03-19 11:50:28 +02:00
Родитель d8ee73369c 21dcb548e6
Коммит 358f816f63
134 изменённых файлов: 682 добавлений и 590 удалений

Просмотреть файл

@ -27,7 +27,7 @@ if [ "$(dirname "$2")" = "$topsrcdir" ]; then
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."

Просмотреть файл

@ -766,26 +766,61 @@ DOMInterfaces = {
'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'
@ -976,6 +1011,11 @@ DOMInterfaces = {
'nativeType': 'mozilla::dom::SVGIRect'
},
'SVGStringList': {
'nativeType': 'mozilla::DOMSVGStringList',
'headerFile': 'DOMSVGStringList.h',
},
'SVGTextContentElement': {
'concrete': False
},
@ -997,11 +1037,6 @@ DOMInterfaces = {
'headerFile': 'DOMSVGTransformList.h'
},
'SVGStringList': {
'nativeType': 'mozilla::DOMSVGStringList',
'headerFile': 'DOMSVGStringList.h',
},
'SVGUnitTypes' : {
'concrete': False,
},

Просмотреть файл

@ -359,7 +359,7 @@ bool TexUnpackBlob::ConvertIfNeeded(
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;

Просмотреть файл

@ -303,10 +303,13 @@ void WebGLContext::BufferData(GLenum target, WebGLsizeiptr size, GLenum usage) {
////
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,

Просмотреть файл

@ -586,7 +586,7 @@ static bool ZeroTextureData(const WebGLContext* webgl, GLuint tex,
const size_t byteCount = checkedByteCount.value();
UniqueBuffer zeros = calloc(1, byteCount);
UniqueBuffer zeros = calloc(1u, byteCount);
if (!zeros) return false;
ScopedUnpackReset scopedReset(webgl);
@ -623,7 +623,7 @@ static bool ZeroTextureData(const WebGLContext* webgl, GLuint tex,
const size_t byteCount = checkedByteCount.value();
UniqueBuffer zeros = calloc(1, byteCount);
UniqueBuffer zeros = calloc(1u, byteCount);
if (!zeros) return false;
ScopedUnpackReset scopedReset(webgl);

Просмотреть файл

@ -1951,12 +1951,12 @@ static bool DoCopyTexOrSubImage(WebGLContext* webgl, bool isSubImage,
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()) {

Просмотреть файл

@ -6,6 +6,8 @@
#ifndef WEBGLTYPES_H_
#define WEBGLTYPES_H_
#include <limits>
// Most WebIDL typedefs are identical to their OpenGL counterparts.
#include "GLTypes.h"
@ -15,11 +17,41 @@ 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,

Просмотреть файл

@ -4,27 +4,28 @@
* 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);
}

Просмотреть файл

@ -4,8 +4,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#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"
@ -19,12 +19,12 @@ 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
@ -35,7 +35,7 @@ class SVGAnimatedAngle final : public nsWrapperCache {
already_AddRefed<DOMSVGAngle> AnimVal();
protected:
~SVGAnimatedAngle();
~DOMSVGAnimatedAngle();
SVGOrient* mVal; // kept alive because it belongs to content
RefPtr<SVGElement> mSVGElement;
@ -44,4 +44,4 @@ class SVGAnimatedAngle final : public nsWrapperCache {
} // namespace dom
} // namespace mozilla
#endif // mozilla_dom_SVGAnimatedAngle_h
#endif // mozilla_dom_DOMSVGAnimatedAngle_h

Просмотреть файл

@ -4,18 +4,20 @@
* 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);
}

Просмотреть файл

@ -4,8 +4,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#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"
@ -15,11 +15,11 @@
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
@ -34,7 +34,7 @@ class SVGAnimatedBoolean final : public nsWrapperCache {
}
protected:
~SVGAnimatedBoolean();
~DOMSVGAnimatedBoolean();
SVGBoolean* mVal; // kept alive because it belongs to content
RefPtr<SVGElement> mSVGElement;
@ -43,4 +43,4 @@ class SVGAnimatedBoolean final : public nsWrapperCache {
} // namespace dom
} // namespace mozilla
#endif // mozilla_dom_SVGAnimatedBoolean_h
#endif // mozilla_dom_DOMSVGAnimatedBoolean_h

Просмотреть файл

@ -4,25 +4,25 @@
* 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);
}

Просмотреть файл

@ -4,8 +4,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef mozilla_dom_SVGAnimatedEnumeration_h
#define mozilla_dom_SVGAnimatedEnumeration_h
#ifndef mozilla_dom_DOMSVGAnimatedEnumeration_h
#define mozilla_dom_DOMSVGAnimatedEnumeration_h
#include "nsWrapperCache.h"
@ -14,10 +14,10 @@
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; }
@ -28,9 +28,9 @@ class SVGAnimatedEnumeration : public nsISupports, public nsWrapperCache {
virtual uint16_t AnimVal() = 0;
protected:
explicit SVGAnimatedEnumeration(SVGElement* aSVGElement)
explicit DOMSVGAnimatedEnumeration(SVGElement* aSVGElement)
: mSVGElement(aSVGElement) {}
virtual ~SVGAnimatedEnumeration(){};
virtual ~DOMSVGAnimatedEnumeration(){};
RefPtr<SVGElement> mSVGElement;
};
@ -38,4 +38,4 @@ class SVGAnimatedEnumeration : public nsISupports, public nsWrapperCache {
} // namespace dom
} // namespace mozilla
#endif // mozilla_dom_SVGAnimatedEnumeration_h
#endif // mozilla_dom_DOMSVGAnimatedEnumeration_h

Просмотреть файл

@ -4,25 +4,26 @@
* 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);
}

Просмотреть файл

@ -4,8 +4,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef mozilla_dom_SVGAnimatedInteger_h
#define mozilla_dom_SVGAnimatedInteger_h
#ifndef mozilla_dom_DOMSVGAnimatedInteger_h
#define mozilla_dom_DOMSVGAnimatedInteger_h
#include "nsWrapperCache.h"
@ -14,10 +14,10 @@
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; }
@ -28,9 +28,9 @@ class SVGAnimatedInteger : public nsISupports, public nsWrapperCache {
virtual int32_t AnimVal() = 0;
protected:
explicit SVGAnimatedInteger(SVGElement* aSVGElement)
explicit DOMSVGAnimatedInteger(SVGElement* aSVGElement)
: mSVGElement(aSVGElement) {}
virtual ~SVGAnimatedInteger(){};
virtual ~DOMSVGAnimatedInteger(){};
RefPtr<SVGElement> mSVGElement;
};
@ -38,4 +38,4 @@ class SVGAnimatedInteger : public nsISupports, public nsWrapperCache {
} // namespace dom
} // namespace mozilla
#endif // mozilla_dom_SVGAnimatedInteger_h
#endif // mozilla_dom_DOMSVGAnimatedInteger_h

Просмотреть файл

@ -4,7 +4,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "mozilla/dom/SVGAnimatedLength.h"
#include "DOMSVGAnimatedLength.h"
#include "mozilla/dom/SVGAnimatedLengthBinding.h"
#include "nsSVGLength2.h"
#include "DOMSVGLength.h"
@ -12,21 +13,22 @@
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);
}

Просмотреть файл

@ -4,8 +4,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#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"
@ -18,12 +18,12 @@ 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
@ -34,7 +34,7 @@ class SVGAnimatedLength final : public nsWrapperCache {
already_AddRefed<DOMSVGLength> AnimVal();
protected:
~SVGAnimatedLength();
~DOMSVGAnimatedLength();
nsSVGLength2* mVal; // kept alive because it belongs to content
RefPtr<SVGElement> mSVGElement;
@ -43,4 +43,4 @@ class SVGAnimatedLength final : public nsWrapperCache {
} // namespace dom
} // namespace mozilla
#endif // mozilla_dom_SVGAnimatedLength_h
#endif // mozilla_dom_DOMSVGAnimatedLength_h

Просмотреть файл

@ -4,25 +4,26 @@
* 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);
}

Просмотреть файл

@ -4,8 +4,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#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"
@ -15,10 +15,10 @@
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; }
@ -29,9 +29,9 @@ class SVGAnimatedNumber : public nsISupports, public nsWrapperCache {
virtual float AnimVal() = 0;
protected:
explicit SVGAnimatedNumber(SVGElement* aSVGElement)
explicit DOMSVGAnimatedNumber(SVGElement* aSVGElement)
: mSVGElement(aSVGElement) {}
virtual ~SVGAnimatedNumber(){};
virtual ~DOMSVGAnimatedNumber(){};
RefPtr<SVGElement> mSVGElement;
};
@ -39,4 +39,4 @@ class SVGAnimatedNumber : public nsISupports, public nsWrapperCache {
} // namespace dom
} // namespace mozilla
#endif // mozilla_dom_SVGAnimatedNumber_h
#endif // mozilla_dom_DOMSVGAnimatedNumber_h

Просмотреть файл

@ -4,14 +4,15 @@
* 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);
}

Просмотреть файл

@ -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 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,
@ -33,4 +33,4 @@ class SVGAnimatedString : public nsISupports, public nsWrapperCache {
} // namespace dom
} // namespace mozilla
#endif // mozilla_dom_SVGAnimatedString_h
#endif // mozilla_dom_DOMSVGAnimatedString_h

Просмотреть файл

@ -6,10 +6,10 @@
#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>

Просмотреть файл

@ -55,7 +55,7 @@ SVGAElement::SVGAElement(already_AddRefed<mozilla::dom::NodeInfo>&& aNodeInfo)
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);
@ -86,7 +86,7 @@ NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGAElement)
//----------------------------------------------------------------------
already_AddRefed<SVGAnimatedString> SVGAElement::Target() {
already_AddRefed<DOMSVGAnimatedString> SVGAElement::Target() {
return mStringAttributes[TARGET].ToDOMAnimatedString(this);
}

Просмотреть файл

@ -67,8 +67,8 @@ class SVGAElement final : public SVGAElementBase, public 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);

Просмотреть файл

@ -6,11 +6,11 @@
#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;
@ -18,9 +18,9 @@ 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;
}
@ -98,19 +98,19 @@ void SVGBoolean::SetAnimValue(bool aValue, SVGElement* aSVGElement) {
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);
}

Просмотреть файл

@ -20,8 +20,8 @@ namespace mozilla {
class SMILValue;
namespace dom {
class DOMSVGAnimatedBoolean;
class SVGAnimationElement;
class SVGAnimatedBoolean;
class SVGElement;
} // namespace dom
@ -44,7 +44,7 @@ class SVGBoolean {
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);

Просмотреть файл

@ -44,15 +44,15 @@ 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);
}

Просмотреть файл

@ -42,9 +42,9 @@ class SVGCircleElement final : public SVGCircleElementBase {
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;

Просмотреть файл

@ -6,21 +6,23 @@
#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
@ -48,7 +50,7 @@ NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(DOMAnimatedString)
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();

Просмотреть файл

@ -20,7 +20,7 @@ namespace mozilla {
class SMILValue;
namespace dom {
class SVGAnimatedString;
class DOMSVGAnimatedString;
class SVGElement;
class SVGClass {
@ -37,7 +37,7 @@ class SVGClass {
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);

Просмотреть файл

@ -33,7 +33,8 @@ 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);
}

Просмотреть файл

@ -36,7 +36,7 @@ class SVGClipPathElement final : public SVGClipPathElementBase {
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.

Просмотреть файл

@ -56,13 +56,13 @@ class SVGComponentTransferFunctionElement
// 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;

Просмотреть файл

@ -7,7 +7,6 @@
#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"
@ -25,6 +24,7 @@
#include "mozilla/SVGContentUtils.h"
#include "mozilla/Unused.h"
#include "DOMSVGAnimatedEnumeration.h"
#include "mozAutoDocUpdate.h"
#include "nsAttrValueOrString.h"
#include "nsCSSProps.h"
@ -1016,7 +1016,7 @@ SVGElement* SVGElement::GetViewportElement() {
return SVGContentUtils::GetNearestViewportElement(this);
}
already_AddRefed<SVGAnimatedString> SVGElement::ClassName() {
already_AddRefed<DOMSVGAnimatedString> SVGElement::ClassName() {
return mClassAttribute.ToDOMAnimatedString(this);
}
@ -2226,7 +2226,6 @@ UniquePtr<SMILAttr> SVGElement::GetAnimatedAttr(int32_t aNamespaceID,
return orient ? orient->ToSMILAttr(this) : nullptr;
}
// preserveAspectRatio:
// viewBox:
if (aName == nsGkAtoms::viewBox) {
SVGViewBox* viewBox = GetViewBox();

Просмотреть файл

@ -303,7 +303,7 @@ class SVGElement : public SVGElementBase // nsIContent
// 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;

Просмотреть файл

@ -49,19 +49,19 @@ 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);
}

Просмотреть файл

@ -42,10 +42,10 @@ class SVGEllipseElement final : public SVGEllipseElementBase {
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;

Просмотреть файл

@ -99,7 +99,7 @@ void SVGEnum::SetAnimValue(uint16_t aValue, SVGElement* aSVGElement) {
aSVGElement->DidAnimateEnum(mAttrEnum);
}
already_AddRefed<SVGAnimatedEnumeration> SVGEnum::ToDOMAnimatedEnum(
already_AddRefed<DOMSVGAnimatedEnumeration> SVGEnum::ToDOMAnimatedEnum(
SVGElement* aSVGElement) {
RefPtr<DOMAnimatedEnum> domAnimatedEnum =
sSVGAnimatedEnumTearoffTable.GetTearoff(this);

Просмотреть файл

@ -7,12 +7,12 @@
#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;
@ -52,7 +52,7 @@ class SVGEnum {
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);
@ -67,14 +67,17 @@ class SVGEnum {
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 {

Просмотреть файл

@ -55,15 +55,15 @@ 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);
}

Просмотреть файл

@ -44,9 +44,9 @@ class SVGFEBlendElement : public SVGFEBlendElementBase {
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;

Просмотреть файл

@ -48,11 +48,11 @@ 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);
}

Просмотреть файл

@ -48,8 +48,8 @@ class SVGFEColorMatrixElement : public SVGFEColorMatrixElementBase {
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:

Просмотреть файл

@ -33,7 +33,7 @@ SVGElement::StringInfo SVGFEComponentTransferElement::sStringInfo[2] = {
NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFEComponentTransferElement)
already_AddRefed<SVGAnimatedString> SVGFEComponentTransferElement::In1() {
already_AddRefed<DOMSVGAnimatedString> SVGFEComponentTransferElement::In1() {
return mStringAttributes[IN1].ToDOMAnimatedString(this);
}

Просмотреть файл

@ -45,7 +45,7 @@ class SVGFEComponentTransferElement : public SVGFEComponentTransferElementBase {
virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
// WebIDL
already_AddRefed<SVGAnimatedString> In1();
already_AddRefed<DOMSVGAnimatedString> In1();
protected:
virtual StringAttributesInfo GetStringInfo() override;

Просмотреть файл

@ -47,31 +47,31 @@ SVGElement::StringInfo SVGFECompositeElement::sStringInfo[3] = {
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);
}

Просмотреть файл

@ -46,13 +46,13 @@ class SVGFECompositeElement : public SVGFECompositeElementBase {
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:

Просмотреть файл

@ -62,16 +62,16 @@ 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);
}
@ -82,39 +82,39 @@ SVGFEConvolveMatrixElement::KernelMatrix() {
&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);

Просмотреть файл

@ -7,7 +7,7 @@
#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"
@ -23,7 +23,7 @@ namespace mozilla {
namespace dom {
class DOMSVGAnimatedNumberList;
class SVGAnimatedBoolean;
class DOMSVGAnimatedBoolean;
typedef SVGFE SVGFEConvolveMatrixElementBase;
@ -54,18 +54,18 @@ class SVGFEConvolveMatrixElement : public SVGFEConvolveMatrixElementBase {
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;

Просмотреть файл

@ -28,27 +28,27 @@ 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);

Просмотреть файл

@ -40,11 +40,11 @@ class SVGFEDiffuseLightingElement : public SVGFEDiffuseLightingElementBase {
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

Просмотреть файл

@ -48,24 +48,24 @@ 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);
}

Просмотреть файл

@ -44,11 +44,11 @@ class SVGFEDisplacementMapElement : public SVGFEDisplacementMapElementBase {
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,

Просмотреть файл

@ -49,11 +49,11 @@ LightType SVGFEDistantLightElement::ComputeLightAttributes(
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);
}

Просмотреть файл

@ -40,8 +40,8 @@ class SVGFEDistantLightElement : public SVGFEDistantLightElementBase {
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;

Просмотреть файл

@ -38,24 +38,24 @@ 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);
}

Просмотреть файл

@ -50,11 +50,11 @@ class SVGFEDropShadowElement : public SVGFEDropShadowElementBase {
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:

Просмотреть файл

@ -35,16 +35,18 @@ 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);
}

Просмотреть файл

@ -46,9 +46,9 @@ class SVGFEGaussianBlurElement : public SVGFEGaussianBlurElementBase {
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:

Просмотреть файл

@ -165,7 +165,7 @@ EventStates SVGFEImageElement::IntrinsicState() const {
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);

Просмотреть файл

@ -79,7 +79,7 @@ class SVGFEImageElement final : public SVGFEImageElementBase,
void MaybeLoadSVGImage();
// WebIDL
already_AddRefed<SVGAnimatedString> Href();
already_AddRefed<DOMSVGAnimatedString> Href();
already_AddRefed<DOMSVGAnimatedPreserveAspectRatio> PreserveAspectRatio();
private:

Просмотреть файл

@ -33,7 +33,7 @@ bool SVGFEMergeNodeElement::AttributeAffectsRendering(
return aNameSpaceID == kNameSpaceID_None && aAttribute == nsGkAtoms::in;
}
already_AddRefed<SVGAnimatedString> SVGFEMergeNodeElement::In1() {
already_AddRefed<DOMSVGAnimatedString> SVGFEMergeNodeElement::In1() {
return mStringAttributes[IN1].ToDOMAnimatedString(this);
}

Просмотреть файл

@ -38,7 +38,7 @@ class SVGFEMergeNodeElement : public SVGFEMergeNodeElementBase {
const SVGString* GetIn1() { return &mStringAttributes[IN1]; }
// WebIDL
already_AddRefed<SVGAnimatedString> In1();
already_AddRefed<DOMSVGAnimatedString> In1();
protected:
virtual StringAttributesInfo GetStringInfo() override;

Просмотреть файл

@ -43,20 +43,20 @@ 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);
}

Просмотреть файл

@ -47,10 +47,10 @@ class SVGFEMorphologyElement : public SVGFEMorphologyElementBase {
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:

Просмотреть файл

@ -34,15 +34,15 @@ 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);
}

Просмотреть файл

@ -46,9 +46,9 @@ class SVGFEOffsetElement : public SVGFEOffsetElementBase {
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;

Просмотреть файл

@ -54,15 +54,15 @@ LightType SVGFEPointLightElement::ComputeLightAttributes(
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);
}

Просмотреть файл

@ -40,9 +40,9 @@ class SVGFEPointLightElement : public SVGFEPointLightElementBase {
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;

Просмотреть файл

@ -26,32 +26,32 @@ JSObject* SVGFESpecularLightingElement::WrapNode(
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);

Просмотреть файл

@ -42,12 +42,12 @@ class SVGFESpecularLightingElement : public SVGFESpecularLightingElementBase {
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

Просмотреть файл

@ -71,35 +71,37 @@ LightType SVGFESpotLightElement::ComputeLightAttributes(
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);
}

Просмотреть файл

@ -41,14 +41,14 @@ class SVGFESpotLightElement : public SVGFESpotLightElementBase {
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;

Просмотреть файл

@ -29,7 +29,7 @@ SVGElement::StringInfo SVGFETileElement::sStringInfo[2] = {
NS_IMPL_ELEMENT_CLONE_WITH_INIT(SVGFETileElement)
already_AddRefed<SVGAnimatedString> SVGFETileElement::In1() {
already_AddRefed<DOMSVGAnimatedString> SVGFETileElement::In1() {
return mStringAttributes[IN1].ToDOMAnimatedString(this);
}

Просмотреть файл

@ -46,7 +46,7 @@ class SVGFETileElement : public SVGFETileElementBase {
virtual nsresult Clone(dom::NodeInfo*, nsINode** aResult) const override;
// WebIDL
already_AddRefed<SVGAnimatedString> In1();
already_AddRefed<DOMSVGAnimatedString> In1();
protected:
virtual StringAttributesInfo GetStringInfo() override;

Просмотреть файл

@ -60,29 +60,32 @@ 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);
}

Просмотреть файл

@ -49,12 +49,12 @@ class SVGFETurbulenceElement : public SVGFETurbulenceElementBase {
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;

Просмотреть файл

@ -62,31 +62,31 @@ 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);

Просмотреть файл

@ -20,7 +20,7 @@ nsresult NS_NewSVGFilterElement(
namespace mozilla {
namespace dom {
class SVGAnimatedLength;
class DOMSVGAnimatedLength;
typedef SVGElement SVGFilterElementBase;
@ -46,13 +46,13 @@ class SVGFilterElement : public SVGFilterElementBase {
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;

Просмотреть файл

@ -8,12 +8,12 @@
#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"
@ -23,7 +23,6 @@
#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"
@ -93,23 +92,23 @@ bool SVGFE::AttributeAffectsRendering(int32_t aNameSpaceID,
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);
}
@ -212,7 +211,7 @@ bool SVGComponentTransferFunctionElement::AttributeAffectsRendering(
//----------------------------------------------------------------------
already_AddRefed<SVGAnimatedEnumeration>
already_AddRefed<DOMSVGAnimatedEnumeration>
SVGComponentTransferFunctionElement::Type() {
return mEnumAttributes[TYPE].ToDOMAnimatedEnum(this);
}
@ -223,27 +222,27 @@ SVGComponentTransferFunctionElement::TableValues() {
&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);
}

Просмотреть файл

@ -126,11 +126,11 @@ class SVGFE : public SVGFEBase {
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) {

Просмотреть файл

@ -47,19 +47,19 @@ 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);
}

Просмотреть файл

@ -43,10 +43,10 @@ class SVGForeignObjectElement final : public SVGGraphicsElement {
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;

Просмотреть файл

@ -179,6 +179,6 @@ float SVGGeometryElement::GetPathLengthScale(PathLengthScaleForType aFor) {
return 1.0;
}
already_AddRefed<SVGAnimatedNumber> SVGGeometryElement::PathLength() {
already_AddRefed<DOMSVGAnimatedNumber> SVGGeometryElement::PathLength() {
return mPathLength.ToDOMAnimatedNumber(this);
}

Просмотреть файл

@ -31,7 +31,7 @@ struct SVGMark {
namespace dom {
class SVGAnimatedNumber;
class DOMSVGAnimatedNumber;
typedef mozilla::dom::SVGGraphicsElement SVGGeometryElementBase;
@ -208,7 +208,7 @@ class SVGGeometryElement : public SVGGeometryElementBase {
float GetPathLengthScale(PathLengthScaleForType aFor);
// WebIDL
already_AddRefed<SVGAnimatedNumber> PathLength();
already_AddRefed<DOMSVGAnimatedNumber> PathLength();
float GetTotalLength();
already_AddRefed<nsISVGPoint> GetPointAtLength(float distance,
ErrorResult& rv);

Просмотреть файл

@ -62,7 +62,8 @@ SVGElement::StringAttributesInfo SVGGradientElement::GetStringInfo() {
ArrayLength(sStringInfo));
}
already_AddRefed<SVGAnimatedEnumeration> SVGGradientElement::GradientUnits() {
already_AddRefed<DOMSVGAnimatedEnumeration>
SVGGradientElement::GradientUnits() {
return mEnumAttributes[GRADIENTUNITS].ToDOMAnimatedEnum(this);
}
@ -74,11 +75,11 @@ SVGGradientElement::GradientTransform() {
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);
@ -128,19 +129,19 @@ 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);
}
@ -196,27 +197,27 @@ 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);
}

Просмотреть файл

@ -54,10 +54,10 @@ class SVGGradientElement : public SVGGradientElementBase {
}
// 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;
@ -96,10 +96,10 @@ class SVGLinearGradientElement : public SVGLinearGradientElementBase {
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;
@ -129,12 +129,12 @@ class SVGRadialGradientElement : public SVGRadialGradientElementBase {
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;

Просмотреть файл

@ -70,19 +70,19 @@ 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);
}
@ -91,7 +91,7 @@ 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);

Просмотреть файл

@ -81,12 +81,12 @@ class SVGImageElement : public SVGImageElementBase,
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);

Просмотреть файл

@ -72,7 +72,7 @@ void SVGInteger::SetAnimValue(int aValue, SVGElement *aSVGElement) {
aSVGElement->DidAnimateInteger(mAttrEnum);
}
already_AddRefed<SVGAnimatedInteger> SVGInteger::ToDOMAnimatedInteger(
already_AddRefed<DOMSVGAnimatedInteger> SVGInteger::ToDOMAnimatedInteger(
SVGElement *aSVGElement) {
RefPtr<DOMAnimatedInteger> domAnimatedInteger =
sSVGAnimatedIntegerTearoffTable.GetTearoff(this);

Просмотреть файл

@ -9,7 +9,7 @@
#include "nsCycleCollectionParticipant.h"
#include "nsError.h"
#include "SVGAnimatedInteger.h"
#include "DOMSVGAnimatedInteger.h"
#include "mozilla/Attributes.h"
#include "mozilla/SMILAttr.h"
#include "mozilla/UniquePtr.h"
@ -50,7 +50,7 @@ class SVGInteger {
// 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);
@ -62,9 +62,9 @@ class SVGInteger {
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

Просмотреть файл

@ -136,7 +136,7 @@ void SVGIntegerPair::SetAnimValue(const int32_t aValue[2],
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)

Просмотреть файл

@ -7,12 +7,12 @@
#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 {
@ -58,7 +58,7 @@ class SVGIntegerPair {
// 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);
@ -70,10 +70,10 @@ class SVGIntegerPair {
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();

Просмотреть файл

@ -61,19 +61,19 @@ 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);
}

Просмотреть файл

@ -48,10 +48,10 @@ class SVGLineElement final : public SVGLineElementBase {
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;

Просмотреть файл

@ -60,7 +60,7 @@ SVGMPathElement::~SVGMPathElement() { UnlinkHrefTarget(false); }
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);

Просмотреть файл

@ -65,7 +65,7 @@ class SVGMPathElement final : public SVGMPathElementBase,
SVGPathElement* GetReferencedPath();
// WebIDL
already_AddRefed<SVGAnimatedString> Href();
already_AddRefed<DOMSVGAnimatedString> Href();
protected:
/**

Просмотреть файл

@ -7,10 +7,10 @@
#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"
@ -78,31 +78,31 @@ SVGMarkerElement::PreserveAspectRatio() {
//----------------------------------------------------------------------
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);
}

Просмотреть файл

@ -7,6 +7,8 @@
#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"
@ -14,8 +16,6 @@
#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"
@ -64,13 +64,13 @@ class SVGMarkerElement : public SVGMarkerElementBase {
// 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);

Просмотреть файл

@ -57,27 +57,27 @@ 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);
}

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше