Bug 1456394 - Rename AnimationEffectReadOnly to AnimationEffect; r=bz,hiro
authorBrian Birtles <birtles@gmail.com>
Mon, 07 May 2018 11:15:16 +0900
changeset 417845 7eae2c106d30b402e5c070bc3ae8b05cc59e78aa
parent 417844 238d0908de38dbeed24a2e288b8b25e64087ec7c
child 417846 97256bd7ef9907b732be9fc1beb89b0757d08679
push id33980
push userebalazs@mozilla.com
push dateFri, 11 May 2018 09:35:12 +0000
treeherdermozilla-central@8e9a4a323f0c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbz, hiro
bugs1456394
milestone62.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1456394 - Rename AnimationEffectReadOnly to AnimationEffect; r=bz,hiro MozReview-Commit-ID: 8jzJiCWt5vs
dom/animation/Animation.cpp
dom/animation/Animation.h
dom/animation/AnimationEffect.cpp
dom/animation/AnimationEffect.h
dom/animation/AnimationEffectReadOnly.cpp
dom/animation/AnimationEffectReadOnly.h
dom/animation/ComputedTiming.h
dom/animation/KeyframeEffect.cpp
dom/animation/KeyframeEffect.h
dom/animation/TimingParams.h
dom/animation/moz.build
dom/base/nsDOMMutationObserver.cpp
dom/base/nsNodeUtils.cpp
dom/bindings/Bindings.conf
dom/tests/mochitest/general/test_interfaces.js
dom/webidl/Animation.webidl
dom/webidl/AnimationEffect.webidl
dom/webidl/AnimationEffectReadOnly.webidl
dom/webidl/KeyframeEffect.webidl
dom/webidl/moz.build
gfx/layers/AnimationHelper.cpp
layout/style/ServoBindings.toml
layout/style/nsAnimationManager.cpp
layout/style/nsCSSProps.cpp
layout/style/nsStyleConsts.h
layout/style/nsStyleStruct.cpp
layout/style/nsTransitionManager.cpp
layout/style/nsTransitionManager.h
testing/web-platform/meta/web-animations/interfaces/KeyframeEffect/idlharness.html.ini
--- a/dom/animation/Animation.cpp
+++ b/dom/animation/Animation.cpp
@@ -83,17 +83,17 @@ namespace {
 
 // ---------------------------------------------------------------------------
 //
 // Animation interface:
 //
 // ---------------------------------------------------------------------------
 /* static */ already_AddRefed<Animation>
 Animation::Constructor(const GlobalObject& aGlobal,
-                       AnimationEffectReadOnly* aEffect,
+                       AnimationEffect* aEffect,
                        const Optional<AnimationTimeline*>& aTimeline,
                        ErrorResult& aRv)
 {
   nsCOMPtr<nsIGlobalObject> global = do_QueryInterface(aGlobal.GetAsSupports());
   RefPtr<Animation> animation = new Animation(global);
 
   AnimationTimeline* timeline;
   if (aTimeline.WasPassed()) {
@@ -120,25 +120,25 @@ Animation::SetId(const nsAString& aId)
   if (mId == aId) {
     return;
   }
   mId = aId;
   nsNodeUtils::AnimationChanged(this);
 }
 
 void
-Animation::SetEffect(AnimationEffectReadOnly* aEffect)
+Animation::SetEffect(AnimationEffect* aEffect)
 {
   SetEffectNoUpdate(aEffect);
   PostUpdate();
 }
 
 // https://drafts.csswg.org/web-animations/#setting-the-target-effect
 void
-Animation::SetEffectNoUpdate(AnimationEffectReadOnly* aEffect)
+Animation::SetEffectNoUpdate(AnimationEffect* aEffect)
 {
   RefPtr<Animation> kungFuDeathGrip(this);
 
   if (mEffect == aEffect) {
     return;
   }
 
   AutoMutationBatchForAnimation mb(*this);
@@ -154,27 +154,27 @@ Animation::SetEffectNoUpdate(AnimationEf
 
     // We need to notify observers now because once we set mEffect to null
     // we won't be able to find the target element to notify.
     if (mIsRelevant) {
       nsNodeUtils::AnimationRemoved(this);
     }
 
     // Break links with the old effect and then drop it.
-    RefPtr<AnimationEffectReadOnly> oldEffect = mEffect;
+    RefPtr<AnimationEffect> oldEffect = mEffect;
     mEffect = nullptr;
     oldEffect->SetAnimation(nullptr);
 
     // The following will not do any notification because mEffect is null.
     UpdateRelevance();
   }
 
   if (aEffect) {
     // Break links from the new effect to its previous animation, if any.
-    RefPtr<AnimationEffectReadOnly> newEffect = aEffect;
+    RefPtr<AnimationEffect> newEffect = aEffect;
     Animation* prevAnim = aEffect->GetAnimation();
     if (prevAnim) {
       prevAnim->SetEffect(nullptr);
     }
 
     // Create links with the new effect. SetAnimation(this) will also update
     // mIsRelevant of this animation, and then notify mutation observer if
     // needed by calling Animation::UpdateRelevance(), so we don't need to
--- a/dom/animation/Animation.h
+++ b/dom/animation/Animation.h
@@ -12,17 +12,17 @@
 #include "mozilla/AnimationPerformanceWarning.h"
 #include "mozilla/Attributes.h"
 #include "mozilla/CycleCollectedJSContext.h"
 #include "mozilla/DOMEventTargetHelper.h"
 #include "mozilla/EffectCompositor.h" // For EffectCompositor::CascadeLevel
 #include "mozilla/LinkedList.h"
 #include "mozilla/TimeStamp.h" // for TimeStamp, TimeDuration
 #include "mozilla/dom/AnimationBinding.h" // for AnimationPlayState
-#include "mozilla/dom/AnimationEffectReadOnly.h"
+#include "mozilla/dom/AnimationEffect.h"
 #include "mozilla/dom/AnimationTimeline.h"
 #include "mozilla/dom/Promise.h"
 #include "nsCSSPropertyID.h"
 #include "nsIGlobalObject.h"
 
 // X11 has a #define for CurrentTime.
 #ifdef CurrentTime
 #undef CurrentTime
@@ -91,23 +91,23 @@ public:
   enum class LimitBehavior {
     AutoRewind,
     Continue
   };
 
   // Animation interface methods
   static already_AddRefed<Animation>
   Constructor(const GlobalObject& aGlobal,
-              AnimationEffectReadOnly* aEffect,
+              AnimationEffect* aEffect,
               const Optional<AnimationTimeline*>& aTimeline,
               ErrorResult& aRv);
   void GetId(nsAString& aResult) const { aResult = mId; }
   void SetId(const nsAString& aId);
-  AnimationEffectReadOnly* GetEffect() const { return mEffect; }
-  void SetEffect(AnimationEffectReadOnly* aEffect);
+  AnimationEffect* GetEffect() const { return mEffect; }
+  void SetEffect(AnimationEffect* aEffect);
   AnimationTimeline* GetTimeline() const { return mTimeline; }
   void SetTimeline(AnimationTimeline* aTimeline);
   Nullable<TimeDuration> GetStartTime() const { return mStartTime; }
   void SetStartTime(const Nullable<TimeDuration>& aNewStartTime);
   Nullable<TimeDuration> GetCurrentTime() const {
     return GetCurrentTimeForHoldTime(mHoldTime);
   }
   void SetCurrentTime(const TimeDuration& aNewCurrentTime);
@@ -150,17 +150,17 @@ public:
    * CSSAnimation::PauseFromJS so we leave it for now.
    */
   void PauseFromJS(ErrorResult& aRv) { Pause(aRv); }
 
   // Wrapper functions for Animation DOM methods when called from style.
 
   virtual void CancelFromStyle() { CancelNoUpdate(); }
   void SetTimelineNoUpdate(AnimationTimeline* aTimeline);
-  void SetEffectNoUpdate(AnimationEffectReadOnly* aEffect);
+  void SetEffectNoUpdate(AnimationEffect* aEffect);
 
   virtual void Tick();
   bool NeedsTicks() const
   {
     return Pending() || PlayState() == AnimationPlayState::Running;
   }
 
   /**
@@ -483,17 +483,17 @@ protected:
   Nullable<TimeDuration> GetUnconstrainedCurrentTime() const
   {
     return GetCurrentTimeForHoldTime(Nullable<TimeDuration>());
   }
 
   nsIDocument* GetRenderedDocument() const;
 
   RefPtr<AnimationTimeline> mTimeline;
-  RefPtr<AnimationEffectReadOnly> mEffect;
+  RefPtr<AnimationEffect> mEffect;
   // The beginning of the delay period.
   Nullable<TimeDuration> mStartTime; // Timeline timescale
   Nullable<TimeDuration> mHoldTime;  // Animation timescale
   Nullable<TimeDuration> mPendingReadyTime; // Timeline timescale
   Nullable<TimeDuration> mPreviousCurrentTime; // Animation timescale
   double mPlaybackRate;
   Maybe<double> mPendingPlaybackRate;
 
rename from dom/animation/AnimationEffectReadOnly.cpp
rename to dom/animation/AnimationEffect.cpp
--- a/dom/animation/AnimationEffectReadOnly.cpp
+++ b/dom/animation/AnimationEffect.cpp
@@ -1,86 +1,86 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#include "mozilla/dom/AnimationEffectReadOnly.h"
-#include "mozilla/dom/AnimationEffectReadOnlyBinding.h"
+#include "mozilla/dom/AnimationEffect.h"
+#include "mozilla/dom/AnimationEffectBinding.h"
 
 #include "mozilla/dom/Animation.h"
 #include "mozilla/dom/KeyframeEffect.h"
 #include "mozilla/AnimationUtils.h"
 #include "mozilla/FloatingPoint.h"
 
 namespace mozilla {
 namespace dom {
 
-NS_IMPL_CYCLE_COLLECTION_CLASS(AnimationEffectReadOnly)
-NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(AnimationEffectReadOnly)
+NS_IMPL_CYCLE_COLLECTION_CLASS(AnimationEffect)
+NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(AnimationEffect)
   if (tmp->mTiming) {
     tmp->mTiming->Unlink();
   }
   NS_IMPL_CYCLE_COLLECTION_UNLINK(mDocument, mTiming, mAnimation)
   NS_IMPL_CYCLE_COLLECTION_UNLINK_PRESERVED_WRAPPER
 NS_IMPL_CYCLE_COLLECTION_UNLINK_END
 
-NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN(AnimationEffectReadOnly)
+NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN(AnimationEffect)
   NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mDocument, mTiming, mAnimation)
 NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
 
-NS_IMPL_CYCLE_COLLECTION_TRACE_WRAPPERCACHE(AnimationEffectReadOnly)
+NS_IMPL_CYCLE_COLLECTION_TRACE_WRAPPERCACHE(AnimationEffect)
 
-NS_IMPL_CYCLE_COLLECTING_ADDREF(AnimationEffectReadOnly)
-NS_IMPL_CYCLE_COLLECTING_RELEASE(AnimationEffectReadOnly)
+NS_IMPL_CYCLE_COLLECTING_ADDREF(AnimationEffect)
+NS_IMPL_CYCLE_COLLECTING_RELEASE(AnimationEffect)
 
-NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(AnimationEffectReadOnly)
+NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(AnimationEffect)
   NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
   NS_INTERFACE_MAP_ENTRY(nsISupports)
 NS_INTERFACE_MAP_END
 
-AnimationEffectReadOnly::AnimationEffectReadOnly(
+AnimationEffect::AnimationEffect(
   nsIDocument* aDocument, AnimationEffectTimingReadOnly* aTiming)
   : mDocument(aDocument)
   , mTiming(aTiming)
 {
   MOZ_ASSERT(aTiming);
 }
 
 // https://drafts.csswg.org/web-animations/#current
 bool
-AnimationEffectReadOnly::IsCurrent() const
+AnimationEffect::IsCurrent() const
 {
   if (!mAnimation || mAnimation->PlayState() == AnimationPlayState::Finished) {
     return false;
   }
 
   ComputedTiming computedTiming = GetComputedTiming();
   return computedTiming.mPhase == ComputedTiming::AnimationPhase::Before ||
          computedTiming.mPhase == ComputedTiming::AnimationPhase::Active;
 }
 
 // https://drafts.csswg.org/web-animations/#in-effect
 bool
-AnimationEffectReadOnly::IsInEffect() const
+AnimationEffect::IsInEffect() const
 {
   ComputedTiming computedTiming = GetComputedTiming();
   return !computedTiming.mProgress.IsNull();
 }
 
 already_AddRefed<AnimationEffectTimingReadOnly>
-AnimationEffectReadOnly::Timing()
+AnimationEffect::Timing()
 {
   RefPtr<AnimationEffectTimingReadOnly> temp(mTiming);
   return temp.forget();
 }
 
 void
-AnimationEffectReadOnly::SetSpecifiedTiming(const TimingParams& aTiming)
+AnimationEffect::SetSpecifiedTiming(const TimingParams& aTiming)
 {
   if (mTiming->AsTimingParams() == aTiming) {
     return;
   }
   mTiming->SetTimingParams(aTiming);
   if (mAnimation) {
     mAnimation->NotifyEffectTimingUpdated();
     if (AsKeyframeEffect()) {
@@ -88,17 +88,17 @@ AnimationEffectReadOnly::SetSpecifiedTim
     }
   }
   // For keyframe effects, NotifyEffectTimingUpdated above will eventually cause
   // KeyframeEffect::NotifyAnimationTimingUpdated to be called so it can
   // update its registration with the target element as necessary.
 }
 
 ComputedTiming
-AnimationEffectReadOnly::GetComputedTimingAt(
+AnimationEffect::GetComputedTimingAt(
     const Nullable<TimeDuration>& aLocalTime,
     const TimingParams& aTiming,
     double aPlaybackRate)
 {
   static const StickyTimeDuration zeroDuration;
 
   // Always return the same object to benefit from return-value optimization.
   ComputedTiming result;
@@ -260,17 +260,17 @@ AnimationEffectReadOnly::GetComputedTimi
   }
 
   MOZ_ASSERT(IsFinite(progress), "Progress value should be finite");
   result.mProgress.SetValue(progress);
   return result;
 }
 
 ComputedTiming
-AnimationEffectReadOnly::GetComputedTiming(const TimingParams* aTiming) const
+AnimationEffect::GetComputedTiming(const TimingParams* aTiming) const
 {
   double playbackRate = mAnimation ? mAnimation->PlaybackRate() : 1;
   return GetComputedTimingAt(GetLocalTime(),
                              aTiming ? *aTiming : SpecifiedTiming(),
                              playbackRate);
 }
 
 // Helper functions for generating a ComputedTimingProperties dictionary
@@ -306,40 +306,40 @@ GetComputedTimingDictionary(const Comput
     double iteration = aComputedTiming.mCurrentIteration == UINT64_MAX
                        ? PositiveInfinity<double>()
                        : static_cast<double>(aComputedTiming.mCurrentIteration);
     aRetVal.mCurrentIteration.SetValue(iteration);
   }
 }
 
 void
-AnimationEffectReadOnly::GetComputedTimingAsDict(
+AnimationEffect::GetComputedTimingAsDict(
   ComputedTimingProperties& aRetVal) const
 {
   double playbackRate = mAnimation ? mAnimation->PlaybackRate() : 1;
   const Nullable<TimeDuration> currentTime = GetLocalTime();
   GetComputedTimingDictionary(GetComputedTimingAt(currentTime,
                                                   SpecifiedTiming(),
                                                   playbackRate),
                               currentTime,
                               SpecifiedTiming(),
                               aRetVal);
 }
 
-AnimationEffectReadOnly::~AnimationEffectReadOnly()
+AnimationEffect::~AnimationEffect()
 {
   // mTiming is cycle collected, so we have to do null check first even though
   // mTiming shouldn't be null during the lifetime of KeyframeEffect.
   if (mTiming) {
     mTiming->Unlink();
   }
 }
 
 Nullable<TimeDuration>
-AnimationEffectReadOnly::GetLocalTime() const
+AnimationEffect::GetLocalTime() const
 {
   // Since the *animation* start time is currently always zero, the local
   // time is equal to the parent time.
   Nullable<TimeDuration> result;
   if (mAnimation) {
     result = mAnimation->GetCurrentTime();
   }
   return result;
rename from dom/animation/AnimationEffectReadOnly.h
rename to dom/animation/AnimationEffect.h
--- a/dom/animation/AnimationEffectReadOnly.h
+++ b/dom/animation/AnimationEffect.h
@@ -1,16 +1,16 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
  * You can obtain one at http://mozilla.org/MPL/2.0/. */
 
-#ifndef mozilla_dom_AnimationEffectReadOnly_h
-#define mozilla_dom_AnimationEffectReadOnly_h
+#ifndef mozilla_dom_AnimationEffect_h
+#define mozilla_dom_AnimationEffect_h
 
 #include "mozilla/ComputedTiming.h"
 #include "mozilla/dom/AnimationEffectTimingReadOnly.h"
 #include "mozilla/dom/BindingDeclarations.h"
 #include "mozilla/dom/Nullable.h"
 #include "mozilla/Maybe.h"
 #include "mozilla/StickyTimeDuration.h"
 #include "mozilla/TimeStamp.h"
@@ -24,25 +24,25 @@ struct ElementPropertyTransition;
 
 namespace dom {
 
 class Animation;
 class AnimationEffectTimingReadOnly;
 class KeyframeEffect;
 struct ComputedTimingProperties;
 
-class AnimationEffectReadOnly : public nsISupports,
-                                public nsWrapperCache
+class AnimationEffect : public nsISupports,
+                        public nsWrapperCache
 {
 public:
   NS_DECL_CYCLE_COLLECTING_ISUPPORTS
-  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(AnimationEffectReadOnly)
+  NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(AnimationEffect)
 
-  AnimationEffectReadOnly(nsIDocument* aDocument,
-                          AnimationEffectTimingReadOnly* aTiming);
+  AnimationEffect(nsIDocument* aDocument,
+                  AnimationEffectTimingReadOnly* aTiming);
 
   virtual KeyframeEffect* AsKeyframeEffect() { return nullptr; }
 
   virtual ElementPropertyTransition* AsTransition() { return nullptr; }
   virtual const ElementPropertyTransition* AsTransition() const
   {
     return nullptr;
   }
@@ -89,22 +89,22 @@ public:
    * Returns true if this effect animates one of the properties we consider
    * geometric properties, e.g. properties such as 'width' or 'margin-left'
    * that we try to synchronize with transform animations, on a valid target
    * element.
    */
   virtual bool AffectsGeometry() const = 0;
 
 protected:
-  virtual ~AnimationEffectReadOnly();
+  virtual ~AnimationEffect();
 
   Nullable<TimeDuration> GetLocalTime() const;
 
 protected:
   RefPtr<nsIDocument> mDocument;
   RefPtr<AnimationEffectTimingReadOnly> mTiming;
   RefPtr<Animation> mAnimation;
 };
 
 } // namespace dom
 } // namespace mozilla
 
-#endif // mozilla_dom_AnimationEffectReadOnly_h
+#endif // mozilla_dom_AnimationEffect_h
--- a/dom/animation/ComputedTiming.h
+++ b/dom/animation/ComputedTiming.h
@@ -6,17 +6,17 @@
 
 #ifndef mozilla_ComputedTiming_h
 #define mozilla_ComputedTiming_h
 
 #include "mozilla/dom/Nullable.h"
 #include "mozilla/StickyTimeDuration.h"
 #include "mozilla/ComputedTimingFunction.h"
 
-#include "mozilla/dom/AnimationEffectReadOnlyBinding.h" // FillMode
+#include "mozilla/dom/AnimationEffectBinding.h" // FillMode
 
 namespace mozilla {
 
 /**
  * Stores the results of calculating the timing properties of an animation
  * at a given sample time.
  */
 struct ComputedTiming
--- a/dom/animation/KeyframeEffect.cpp
+++ b/dom/animation/KeyframeEffect.cpp
@@ -50,28 +50,28 @@ PropertyValuePair::operator==(const Prop
   }
   return Servo_DeclarationBlock_Equals(mServoDeclarationBlock,
                                        aOther.mServoDeclarationBlock);
 }
 
 namespace dom {
 
 NS_IMPL_CYCLE_COLLECTION_INHERITED(KeyframeEffect,
-                                   AnimationEffectReadOnly,
+                                   AnimationEffect,
                                    mTarget)
 
 NS_IMPL_CYCLE_COLLECTION_TRACE_BEGIN_INHERITED(KeyframeEffect,
-                                               AnimationEffectReadOnly)
+                                               AnimationEffect)
 NS_IMPL_CYCLE_COLLECTION_TRACE_END
 
 NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(KeyframeEffect)
-NS_INTERFACE_MAP_END_INHERITING(AnimationEffectReadOnly)
+NS_INTERFACE_MAP_END_INHERITING(AnimationEffect)
 
-NS_IMPL_ADDREF_INHERITED(KeyframeEffect, AnimationEffectReadOnly)
-NS_IMPL_RELEASE_INHERITED(KeyframeEffect, AnimationEffectReadOnly)
+NS_IMPL_ADDREF_INHERITED(KeyframeEffect, AnimationEffect)
+NS_IMPL_RELEASE_INHERITED(KeyframeEffect, AnimationEffect)
 
 KeyframeEffect::KeyframeEffect(
   nsIDocument* aDocument,
   const Maybe<OwningAnimationTarget>& aTarget,
   const TimingParams& aTiming,
   const KeyframeEffectParams& aOptions)
   : KeyframeEffect(aDocument, aTarget,
                    new AnimationEffectTiming(aDocument, aTiming, this),
@@ -79,17 +79,17 @@ KeyframeEffect::KeyframeEffect(
 {
 }
 
 KeyframeEffect::KeyframeEffect(
   nsIDocument* aDocument,
   const Maybe<OwningAnimationTarget>& aTarget,
   AnimationEffectTimingReadOnly* aTiming,
   const KeyframeEffectParams& aOptions)
-  : AnimationEffectReadOnly(aDocument, aTiming)
+  : AnimationEffect(aDocument, aTiming)
   , mTarget(aTarget)
   , mEffectOptions(aOptions)
   , mInEffectOnLastAnimationTimingUpdate(false)
   , mCumulativeChangeHint(nsChangeHint(0))
 {
 }
 
 JSObject*
--- a/dom/animation/KeyframeEffect.h
+++ b/dom/animation/KeyframeEffect.h
@@ -21,17 +21,17 @@
 #include "mozilla/Attributes.h"
 #include "mozilla/ComputedTimingFunction.h"
 #include "mozilla/EffectCompositor.h"
 #include "mozilla/Keyframe.h"
 #include "mozilla/KeyframeEffectParams.h"
 // RawServoDeclarationBlock and associated RefPtrTraits
 #include "mozilla/ServoBindingTypes.h"
 #include "mozilla/StyleAnimationValue.h"
-#include "mozilla/dom/AnimationEffectReadOnly.h"
+#include "mozilla/dom/AnimationEffect.h"
 #include "mozilla/dom/BindingDeclarations.h"
 #include "mozilla/dom/Element.h"
 
 struct JSContext;
 class JSObject;
 class nsIContent;
 class nsIDocument;
 class nsIFrame;
@@ -107,27 +107,27 @@ struct AnimationProperty
 };
 
 struct ElementPropertyTransition;
 
 namespace dom {
 
 class Animation;
 
-class KeyframeEffect : public AnimationEffectReadOnly
+class KeyframeEffect : public AnimationEffect
 {
 public:
   KeyframeEffect(nsIDocument* aDocument,
                  const Maybe<OwningAnimationTarget>& aTarget,
                  const TimingParams& aTiming,
                  const KeyframeEffectParams& aOptions);
 
   NS_DECL_ISUPPORTS_INHERITED
   NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS_INHERITED(KeyframeEffect,
-                                                        AnimationEffectReadOnly)
+                                                         AnimationEffect)
 
   virtual JSObject* WrapObject(JSContext* aCx,
                                JS::Handle<JSObject*> aGivenProto) override;
 
   KeyframeEffect* AsKeyframeEffect() override { return this; }
 
   // KeyframeEffect interface
   static already_AddRefed<KeyframeEffect>
--- a/dom/animation/TimingParams.h
+++ b/dom/animation/TimingParams.h
@@ -10,18 +10,18 @@
 #include "nsStringFwd.h"
 #include "mozilla/dom/Nullable.h"
 #include "mozilla/dom/UnionTypes.h" // For OwningUnrestrictedDoubleOrString
 #include "mozilla/ComputedTimingFunction.h"
 #include "mozilla/Maybe.h"
 #include "mozilla/StickyTimeDuration.h"
 #include "mozilla/TimeStamp.h" // for TimeDuration
 
-#include "mozilla/dom/AnimationEffectReadOnlyBinding.h" // for FillMode
-                                                        // and PlaybackDirection
+#include "mozilla/dom/AnimationEffectBinding.h" // for FillMode
+                                                // and PlaybackDirection
 
 class nsIDocument;
 
 namespace mozilla {
 
 namespace dom {
 class UnrestrictedDoubleOrKeyframeEffectOptions;
 class UnrestrictedDoubleOrKeyframeAnimationOptions;
--- a/dom/animation/moz.build
+++ b/dom/animation/moz.build
@@ -7,17 +7,17 @@
 with Files("**"):
     BUG_COMPONENT = ("Core", "DOM: Animation")
 
 MOCHITEST_MANIFESTS += ['test/mochitest.ini']
 MOCHITEST_CHROME_MANIFESTS += ['test/chrome.ini']
 
 EXPORTS.mozilla.dom += [
     'Animation.h',
-    'AnimationEffectReadOnly.h',
+    'AnimationEffect.h',
     'AnimationEffectTiming.h',
     'AnimationEffectTimingReadOnly.h',
     'AnimationTimeline.h',
     'CSSPseudoElement.h',
     'DocumentTimeline.h',
     'KeyframeEffect.h',
 ]
 
@@ -37,17 +37,17 @@ EXPORTS.mozilla += [
     'KeyframeUtils.h',
     'PendingAnimationTracker.h',
     'PseudoElementHashEntry.h',
     'TimingParams.h',
 ]
 
 UNIFIED_SOURCES += [
     'Animation.cpp',
-    'AnimationEffectReadOnly.cpp',
+    'AnimationEffect.cpp',
     'AnimationEffectTiming.cpp',
     'AnimationEffectTimingReadOnly.cpp',
     'AnimationEventDispatcher.cpp',
     'AnimationPerformanceWarning.cpp',
     'AnimationTimeline.cpp',
     'AnimationUtils.cpp',
     'ComputedTimingFunction.cpp',
     'CSSPseudoElement.cpp',
--- a/dom/base/nsDOMMutationObserver.cpp
+++ b/dom/base/nsDOMMutationObserver.cpp
@@ -375,17 +375,17 @@ void nsMutationReceiver::NodeWillBeDestr
   NS_ASSERTION(!mParent, "Shouldn't have mParent here!");
   Disconnect(true);
 }
 
 void
 nsAnimationReceiver::RecordAnimationMutation(Animation* aAnimation,
                                              AnimationMutation aMutationType)
 {
-  mozilla::dom::AnimationEffectReadOnly* effect = aAnimation->GetEffect();
+  mozilla::dom::AnimationEffect* effect = aAnimation->GetEffect();
   if (!effect) {
     return;
   }
 
   mozilla::dom::KeyframeEffect* keyframeEffect = effect->AsKeyframeEffect();
   if (!keyframeEffect) {
     return;
   }
--- a/dom/base/nsNodeUtils.cpp
+++ b/dom/base/nsNodeUtils.cpp
@@ -230,17 +230,17 @@ nsNodeUtils::ContentRemoved(nsINode* aCo
   IMPL_MUTATION_NOTIFICATION(ContentRemoved, aContainer,
                              (aChild, aPreviousSibling),
                              IsRemoveNotification::Yes);
 }
 
 Maybe<NonOwningAnimationTarget>
 nsNodeUtils::GetTargetForAnimation(const Animation* aAnimation)
 {
-  AnimationEffectReadOnly* effect = aAnimation->GetEffect();
+  AnimationEffect* effect = aAnimation->GetEffect();
   if (!effect || !effect->AsKeyframeEffect()) {
     return Nothing();
   }
   return effect->AsKeyframeEffect()->GetTarget();
 }
 
 void
 nsNodeUtils::AnimationMutated(Animation* aAnimation,
--- a/dom/bindings/Bindings.conf
+++ b/dom/bindings/Bindings.conf
@@ -53,17 +53,17 @@ DOMInterfaces = {
     'concrete': False
 },
 
 'AddonManagerPermissions': {
     'wrapperCache': False,
     'concrete': False
 },
 
-'AnimationEffectReadOnly': {
+'AnimationEffect': {
     'concrete': False
 },
 
 'AnimationTimeline': {
     'concrete': False
 },
 
 'AnonymousContent': {
--- a/dom/tests/mochitest/general/test_interfaces.js
+++ b/dom/tests/mochitest/general/test_interfaces.js
@@ -120,17 +120,17 @@ var interfaceNamesInGlobalScope =
     {name: "AbortController", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "AbortSignal", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "AnalyserNode", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "Animation", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
-    {name: "AnimationEffectReadOnly", insecureContext: true, release: false},
+    {name: "AnimationEffect", insecureContext: true, release: false},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "AnimationEffectTiming", insecureContext: true, release: false},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "AnimationEffectTimingReadOnly", insecureContext: true, release: false},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "AnimationEvent", insecureContext: true},
 // IMPORTANT: Do not change this list without review from a DOM peer!
     {name: "AnimationPlaybackEvent", insecureContext: true, release: false},
--- a/dom/webidl/Animation.webidl
+++ b/dom/webidl/Animation.webidl
@@ -8,22 +8,22 @@
  *
  * Copyright © 2015 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
  * liability, trademark and document use rules apply.
  */
 
 enum AnimationPlayState { "idle", "running", "paused", "finished" };
 
 [Func="nsDocument::IsElementAnimateEnabled",
- Constructor (optional AnimationEffectReadOnly? effect = null,
+ Constructor (optional AnimationEffect? effect = null,
               optional AnimationTimeline? timeline)]
 interface Animation : EventTarget {
   attribute DOMString id;
   [Func="nsDocument::IsWebAnimationsEnabled", Pure]
-  attribute AnimationEffectReadOnly? effect;
+  attribute AnimationEffect? effect;
   [Func="nsDocument::IsWebAnimationsEnabled"]
   attribute AnimationTimeline? timeline;
   [BinaryName="startTimeAsDouble"]
   attribute double? startTime;
   [SetterThrows, BinaryName="currentTimeAsDouble"]
   attribute double? currentTime;
 
            attribute double             playbackRate;
rename from dom/webidl/AnimationEffectReadOnly.webidl
rename to dom/webidl/AnimationEffect.webidl
--- a/dom/webidl/AnimationEffectReadOnly.webidl
+++ b/dom/webidl/AnimationEffect.webidl
@@ -40,14 +40,14 @@ dictionary ComputedTimingProperties : An
   unrestricted double   endTime = 0.0;
   unrestricted double   activeDuration = 0.0;
   double?               localTime = null;
   double?               progress = null;
   unrestricted double?  currentIteration = null;
 };
 
 [Func="nsDocument::IsWebAnimationsEnabled"]
-interface AnimationEffectReadOnly {
+interface AnimationEffect {
   [Cached, Constant]
   readonly attribute AnimationEffectTimingReadOnly timing;
   [BinaryName="getComputedTimingAsDict"]
   ComputedTimingProperties getComputedTiming();
 };
--- a/dom/webidl/KeyframeEffect.webidl
+++ b/dom/webidl/KeyframeEffect.webidl
@@ -23,17 +23,17 @@ dictionary KeyframeEffectOptions : Anima
 // KeyframeEffect should run in the caller's compartment to do custom
 // processing on the `keyframes` object.
 [Func="nsDocument::IsWebAnimationsEnabled",
  RunConstructorInCallerCompartment,
  Constructor ((Element or CSSPseudoElement)? target,
               object? keyframes,
               optional (unrestricted double or KeyframeEffectOptions) options),
  Constructor (KeyframeEffect source)]
-interface KeyframeEffect : AnimationEffectReadOnly {
+interface KeyframeEffect : AnimationEffect {
   attribute (Element or CSSPseudoElement)?  target;
   [NeedsCallerType]
   attribute IterationCompositeOperation     iterationComposite;
   attribute CompositeOperation              composite;
   [Throws] sequence<object> getKeyframes ();
   [Throws] void             setKeyframes (object? keyframes);
 };
 
--- a/dom/webidl/moz.build
+++ b/dom/webidl/moz.build
@@ -359,17 +359,17 @@ WEBIDL_FILES = [
     'AbortController.webidl',
     'AbortSignal.webidl',
     'AboutCapabilities.webidl',
     'AbstractWorker.webidl',
     'AddonManager.webidl',
     'AnalyserNode.webidl',
     'Animatable.webidl',
     'Animation.webidl',
-    'AnimationEffectReadOnly.webidl',
+    'AnimationEffect.webidl',
     'AnimationEffectTiming.webidl',
     'AnimationEffectTimingReadOnly.webidl',
     'AnimationEvent.webidl',
     'AnimationTimeline.webidl',
     'AnonymousContent.webidl',
     'AppInfo.webidl',
     'AppNotificationServiceOptions.webidl',
     'APZTestData.webidl',
--- a/gfx/layers/AnimationHelper.cpp
+++ b/gfx/layers/AnimationHelper.cpp
@@ -1,17 +1,17 @@
 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
 /* This Source Code Form is subject to the terms of the Mozilla Public
  * License, v. 2.0. If a copy of the MPL was not distributed with this
  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
 
 #include "AnimationHelper.h"
 #include "mozilla/ComputedTimingFunction.h" // for ComputedTimingFunction
-#include "mozilla/dom/AnimationEffectReadOnlyBinding.h" // for dom::FillMode
+#include "mozilla/dom/AnimationEffectBinding.h" // for dom::FillMode
 #include "mozilla/dom/KeyframeEffectBinding.h" // for dom::IterationComposite
 #include "mozilla/dom/KeyframeEffect.h" // for dom::KeyFrameEffectReadOnly
 #include "mozilla/dom/Nullable.h" // for dom::Nullable
 #include "mozilla/layers/CompositorThread.h" // for CompositorThreadHolder
 #include "mozilla/layers/LayerAnimationUtils.h" // for TimingFunctionToComputedTimingFunction
 #include "mozilla/ServoBindings.h" // for Servo_ComposeAnimationSegment, etc
 #include "mozilla/StyleAnimationValue.h" // for StyleAnimationValue, etc
 #include "nsDeviceContext.h"            // for AppUnitsPerCSSPixel
@@ -228,17 +228,17 @@ AnimationHelper::SampleAnimationForEachN
       animation.isNotPlaying() ||
       animation.startTime().type() != MaybeTimeDuration::TTimeDuration
       ? animation.holdTime()
       : (timeStamp - animation.originTime() -
          animation.startTime().get_TimeDuration())
         .MultDouble(animation.playbackRate());
 
     ComputedTiming computedTiming =
-      dom::AnimationEffectReadOnly::GetComputedTimingAt(
+      dom::AnimationEffect::GetComputedTimingAt(
         dom::Nullable<TimeDuration>(elapsedDuration), animData.mTiming,
         animation.playbackRate());
 
     if (computedTiming.mProgress.IsNull()) {
       continue;
     }
 
     dom::IterationCompositeOperation iterCompositeOperation =
--- a/layout/style/ServoBindings.toml
+++ b/layout/style/ServoBindings.toml
@@ -50,17 +50,17 @@ args = [
 headers = [
     "nsStyleStruct.h",
     "mozilla/StyleAnimationValue.h",
     "gfxFontConstants.h",
     "gfxFontFeatures.h",
     "nsThemeConstants.h",
     "mozilla/css/Loader.h",
     "mozilla/css/SheetLoadData.h",
-    "mozilla/dom/AnimationEffectReadOnlyBinding.h",
+    "mozilla/dom/AnimationEffectBinding.h",
     "mozilla/dom/HTMLSlotElement.h",
     "mozilla/dom/KeyframeEffectBinding.h",
     "mozilla/dom/MediaList.h",
     "mozilla/dom/ShadowRoot.h",
     "mozilla/AnimationPropertySegment.h",
     "mozilla/ComputedTiming.h",
     "mozilla/ComputedTimingFunction.h",
     "mozilla/Keyframe.h",
--- a/layout/style/nsAnimationManager.cpp
+++ b/layout/style/nsAnimationManager.cpp
@@ -10,17 +10,17 @@
 
 #include "mozilla/AnimationEventDispatcher.h"
 #include "mozilla/AnimationTarget.h"
 #include "mozilla/EffectCompositor.h"
 #include "mozilla/EffectSet.h"
 #include "mozilla/MemoryReporting.h"
 #include "mozilla/ServoStyleSet.h"
 #include "mozilla/StyleAnimationValue.h"
-#include "mozilla/dom/AnimationEffectReadOnly.h"
+#include "mozilla/dom/AnimationEffect.h"
 #include "mozilla/dom/DocumentTimeline.h"
 #include "mozilla/dom/KeyframeEffect.h"
 
 #include "nsPresContext.h"
 #include "nsStyleChangeList.h"
 #include "nsContentUtils.h"
 #include "nsLayoutUtils.h"
 #include "nsIFrame.h"
@@ -30,17 +30,17 @@
 #include "nsIPresShellInlines.h"
 #include "nsRFPService.h"
 #include <algorithm> // std::stable_sort
 #include <math.h>
 
 using namespace mozilla;
 using namespace mozilla::css;
 using mozilla::dom::Animation;
-using mozilla::dom::AnimationEffectReadOnly;
+using mozilla::dom::AnimationEffect;
 using mozilla::dom::AnimationPlayState;
 using mozilla::dom::KeyframeEffect;
 using mozilla::dom::CSSAnimation;
 
 typedef mozilla::ComputedTiming::AnimationPhase AnimationPhase;
 
 ////////////////////////// CSSAnimation ////////////////////////////
 
@@ -396,17 +396,17 @@ public:
   // As a result, when we are using the Servo backend, whenever we have an added
   // or removed animation we need to explicitly trigger a restyle.
   //
   // This code should eventually disappear along with the Gecko style backend
   // and we should simply call Play() / Pause() / Cancel() etc. which will
   // post the required restyles.
   void NotifyNewOrRemovedAnimation(const Animation& aAnimation)
   {
-    dom::AnimationEffectReadOnly* effect = aAnimation.GetEffect();
+    dom::AnimationEffect* effect = aAnimation.GetEffect();
     if (!effect) {
       return;
     }
 
     KeyframeEffect* keyframeEffect = effect->AsKeyframeEffect();
     if (!keyframeEffect) {
       return;
     }
@@ -427,17 +427,17 @@ UpdateOldAnimationPropertiesWithNew(
     bool aNewIsStylePaused,
     ServoCSSAnimationBuilder& aBuilder)
 {
   bool animationChanged = false;
 
   // Update the old from the new so we can keep the original object
   // identity (and any expando properties attached to it).
   if (aOld.GetEffect()) {
-    dom::AnimationEffectReadOnly* oldEffect = aOld.GetEffect();
+    dom::AnimationEffect* oldEffect = aOld.GetEffect();
     animationChanged = oldEffect->SpecifiedTiming() != aNewTiming;
     oldEffect->SetSpecifiedTiming(aNewTiming);
 
     KeyframeEffect* oldKeyframeEffect = oldEffect->AsKeyframeEffect();
     if (oldKeyframeEffect) {
       aBuilder.SetKeyframes(*oldKeyframeEffect, Move(aNewKeyframes));
     }
   }
--- a/layout/style/nsCSSProps.cpp
+++ b/layout/style/nsCSSProps.cpp
@@ -15,17 +15,17 @@
 #include "mozilla/Casting.h"
 
 #include "nsCSSKeywords.h"
 #include "nsLayoutUtils.h"
 #include "nsStyleConsts.h"
 #include "nsIWidget.h"
 #include "nsThemeConstants.h"  // For system widget appearance types
 
-#include "mozilla/dom/AnimationEffectReadOnlyBinding.h" // for PlaybackDirection
+#include "mozilla/dom/AnimationEffectBinding.h" // for PlaybackDirection
 #include "mozilla/LookAndFeel.h" // for system colors
 
 #include "nsString.h"
 #include "nsStaticNameTable.h"
 
 #include "mozilla/Preferences.h"
 #include "mozilla/StaticPrefs.h"
 
--- a/layout/style/nsStyleConsts.h
+++ b/layout/style/nsStyleConsts.h
@@ -234,18 +234,18 @@ enum class StyleOrient : uint8_t {
 // See nsStyleDisplay
 #define NS_STYLE_WILL_CHANGE_STACKING_CONTEXT   (1<<0)
 #define NS_STYLE_WILL_CHANGE_TRANSFORM          (1<<1)
 #define NS_STYLE_WILL_CHANGE_SCROLL             (1<<2)
 #define NS_STYLE_WILL_CHANGE_OPACITY            (1<<3)
 #define NS_STYLE_WILL_CHANGE_FIXPOS_CB          (1<<4)
 #define NS_STYLE_WILL_CHANGE_ABSPOS_CB          (1<<5)
 
-// See AnimationEffectReadOnly.webidl
-// and mozilla/dom/AnimationEffectReadOnlyBinding.h
+// See AnimationEffect.webidl
+// and mozilla/dom/AnimationEffectBinding.h
 namespace dom {
 enum class PlaybackDirection : uint8_t;
 enum class FillMode : uint8_t;
 }
 
 // See nsStyleDisplay
 #define NS_STYLE_ANIMATION_ITERATION_COUNT_INFINITE 0
 
--- a/layout/style/nsStyleStruct.cpp
+++ b/layout/style/nsStyleStruct.cpp
@@ -26,17 +26,17 @@
 
 #include "nsBidiUtils.h"
 #include "nsLayoutUtils.h"
 
 #include "imgIRequest.h"
 #include "imgIContainer.h"
 #include "CounterStyleManager.h"
 
-#include "mozilla/dom/AnimationEffectReadOnlyBinding.h" // for PlaybackDirection
+#include "mozilla/dom/AnimationEffectBinding.h" // for PlaybackDirection
 #include "mozilla/dom/DocGroup.h"
 #include "mozilla/dom/ImageTracker.h"
 #include "mozilla/CORSMode.h"
 #include "mozilla/ClearOnShutdown.h"
 #include "mozilla/Likely.h"
 #include "nsIURI.h"
 #include "nsIDocument.h"
 #include <algorithm>
--- a/layout/style/nsTransitionManager.cpp
+++ b/layout/style/nsTransitionManager.cpp
@@ -388,17 +388,17 @@ CSSTransition::GetCurrentTimeAt(const do
     result.SetValue((timelineTime.Value() - aStartTime)
                       .MultDouble(aPlaybackRate));
   }
 
   return result;
 }
 
 void
-CSSTransition::SetEffectFromStyle(dom::AnimationEffectReadOnly* aEffect)
+CSSTransition::SetEffectFromStyle(dom::AnimationEffect* aEffect)
 {
   Animation::SetEffectNoUpdate(aEffect);
 
   // Initialize transition property.
   ElementPropertyTransition* pt = aEffect ? aEffect->AsTransition() : nullptr;
   if (eCSSProperty_UNKNOWN == mTransitionProperty && pt) {
     mTransitionProperty = pt->TransitionProperty();
     mTransitionToValue = pt->ToValue();
--- a/layout/style/nsTransitionManager.h
+++ b/layout/style/nsTransitionManager.h
@@ -165,17 +165,17 @@ public:
     // It is important we do this *after* calling CancelFromStyle().
     // This is because CancelFromStyle() will end up posting a restyle and
     // that restyle should target the *transitions* level of the cascade.
     // However, once we clear the owning element, CascadeLevel() will begin
     // returning CascadeLevel::Animations.
     mOwningElement = OwningElementRef();
   }
 
-  void SetEffectFromStyle(AnimationEffectReadOnly* aEffect);
+  void SetEffectFromStyle(AnimationEffect* aEffect);
 
   void Tick() override;
 
   nsCSSPropertyID TransitionProperty() const;
   AnimationValue ToValue() const;
 
   bool HasLowerCompositeOrderThan(const CSSTransition& aOther) const;
   EffectCompositor::CascadeLevel CascadeLevel() const override
deleted file mode 100644
--- a/testing/web-platform/meta/web-animations/interfaces/KeyframeEffect/idlharness.html.ini
+++ /dev/null
@@ -1,6 +0,0 @@
-[idlharness.html]
-  [KeyframeEffect interface: existence and properties of interface object]
-    expected: FAIL
-
-  [KeyframeEffect interface: existence and properties of interface prototype object]
-    expected: FAIL