mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Backed out changeset 1b5fc672f0d4 (bug 1159082) for B2G ICS Emulator opt R6 test failures on a CLOSED TREE
This commit is contained in:
parent
a729e93945
commit
5791ead1d5
@ -39,7 +39,7 @@ Animation::WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
void
|
||||
Animation::SetEffect(KeyframeEffectReadOnly* aEffect)
|
||||
Animation::SetEffect(KeyframeEffectReadonly* aEffect)
|
||||
{
|
||||
if (mEffect) {
|
||||
mEffect->SetParentTime(Nullable<TimeDuration>());
|
||||
|
@ -12,7 +12,7 @@
|
||||
#include "mozilla/TimeStamp.h" // for TimeStamp, TimeDuration
|
||||
#include "mozilla/dom/AnimationBinding.h" // for AnimationPlayState
|
||||
#include "mozilla/dom/DocumentTimeline.h" // for DocumentTimeline
|
||||
#include "mozilla/dom/KeyframeEffect.h" // for KeyframeEffectReadOnly
|
||||
#include "mozilla/dom/KeyframeEffect.h" // for KeyframeEffectReadonly
|
||||
#include "mozilla/dom/Promise.h" // for Promise
|
||||
#include "nsCSSProperty.h" // for nsCSSProperty
|
||||
|
||||
@ -86,8 +86,8 @@ public:
|
||||
|
||||
// Animation interface methods
|
||||
|
||||
KeyframeEffectReadOnly* GetEffect() const { return mEffect; }
|
||||
void SetEffect(KeyframeEffectReadOnly* aEffect);
|
||||
KeyframeEffectReadonly* GetEffect() const { return mEffect; }
|
||||
void SetEffect(KeyframeEffectReadonly* aEffect);
|
||||
DocumentTimeline* Timeline() const { return mTimeline; }
|
||||
Nullable<TimeDuration> GetStartTime() const { return mStartTime; }
|
||||
void SetStartTime(const Nullable<TimeDuration>& aNewStartTime);
|
||||
@ -318,7 +318,7 @@ protected:
|
||||
AnimationCollection* GetCollection() const;
|
||||
|
||||
nsRefPtr<DocumentTimeline> mTimeline;
|
||||
nsRefPtr<KeyframeEffectReadOnly> mEffect;
|
||||
nsRefPtr<KeyframeEffectReadonly> mEffect;
|
||||
// The beginning of the delay period.
|
||||
Nullable<TimeDuration> mStartTime; // Timeline timescale
|
||||
Nullable<TimeDuration> mHoldTime; // Animation timescale
|
||||
|
@ -3,18 +3,18 @@
|
||||
* 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/AnimationEffectReadonly.h"
|
||||
#include "mozilla/dom/AnimationEffectReadonlyBinding.h"
|
||||
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE(AnimationEffectReadOnly, mParent)
|
||||
NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE(AnimationEffectReadonly, mParent)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTING_ADDREF(AnimationEffectReadOnly)
|
||||
NS_IMPL_CYCLE_COLLECTING_RELEASE(AnimationEffectReadOnly)
|
||||
NS_IMPL_CYCLE_COLLECTING_ADDREF(AnimationEffectReadonly)
|
||||
NS_IMPL_CYCLE_COLLECTING_RELEASE(AnimationEffectReadonly)
|
||||
|
||||
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(AnimationEffectReadOnly)
|
||||
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(AnimationEffectReadonly)
|
||||
NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
|
||||
NS_INTERFACE_MAP_ENTRY(nsISupports)
|
||||
NS_INTERFACE_MAP_END
|
||||
|
@ -14,18 +14,18 @@
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
||||
class AnimationEffectReadOnly
|
||||
class AnimationEffectReadonly
|
||||
: public nsISupports
|
||||
, public nsWrapperCache
|
||||
{
|
||||
protected:
|
||||
virtual ~AnimationEffectReadOnly() { }
|
||||
virtual ~AnimationEffectReadonly() { }
|
||||
|
||||
public:
|
||||
NS_DECL_CYCLE_COLLECTING_ISUPPORTS
|
||||
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(AnimationEffectReadOnly)
|
||||
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(AnimationEffectReadonly)
|
||||
|
||||
explicit AnimationEffectReadOnly(nsISupports* aParent)
|
||||
explicit AnimationEffectReadonly(nsISupports* aParent)
|
||||
: mParent(aParent)
|
||||
{
|
||||
}
|
||||
|
23
dom/animation/AnimationEffectReadonly.cpp
Normal file
23
dom/animation/AnimationEffectReadonly.cpp
Normal file
@ -0,0 +1,23 @@
|
||||
/* vim: set shiftwidth=2 tabstop=8 autoindent cindent expandtab: */
|
||||
/* 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"
|
||||
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE(AnimationEffectReadonly, mParent)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTING_ADDREF(AnimationEffectReadonly)
|
||||
NS_IMPL_CYCLE_COLLECTING_RELEASE(AnimationEffectReadonly)
|
||||
|
||||
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(AnimationEffectReadonly)
|
||||
NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
|
||||
NS_INTERFACE_MAP_ENTRY(nsISupports)
|
||||
NS_INTERFACE_MAP_END
|
||||
|
||||
} // namespace dom
|
||||
} // namespace mozilla
|
42
dom/animation/AnimationEffectReadonly.h
Normal file
42
dom/animation/AnimationEffectReadonly.h
Normal file
@ -0,0 +1,42 @@
|
||||
/* vim: set shiftwidth=2 tabstop=8 autoindent cindent expandtab: */
|
||||
/* 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_AnimationEffect_h
|
||||
#define mozilla_dom_AnimationEffect_h
|
||||
|
||||
#include "nsISupports.h"
|
||||
#include "nsWrapperCache.h"
|
||||
#include "nsCycleCollectionParticipant.h"
|
||||
#include "nsCOMPtr.h"
|
||||
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
||||
class AnimationEffectReadonly
|
||||
: public nsISupports
|
||||
, public nsWrapperCache
|
||||
{
|
||||
protected:
|
||||
virtual ~AnimationEffectReadonly() { }
|
||||
|
||||
public:
|
||||
NS_DECL_CYCLE_COLLECTING_ISUPPORTS
|
||||
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(AnimationEffectReadonly)
|
||||
|
||||
explicit AnimationEffectReadonly(nsISupports* aParent)
|
||||
: mParent(aParent)
|
||||
{
|
||||
}
|
||||
|
||||
nsISupports* GetParentObject() const { return mParent; }
|
||||
|
||||
protected:
|
||||
nsCOMPtr<nsISupports> mParent;
|
||||
};
|
||||
|
||||
} // namespace dom
|
||||
} // namespace mozilla
|
||||
|
||||
#endif // mozilla_dom_AnimationEffect_h
|
@ -59,35 +59,35 @@ const double ComputedTiming::kNullTimeFraction = PositiveInfinity<double>();
|
||||
|
||||
namespace dom {
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_INHERITED(KeyframeEffectReadOnly,
|
||||
AnimationEffectReadOnly,
|
||||
NS_IMPL_CYCLE_COLLECTION_INHERITED(KeyframeEffectReadonly,
|
||||
AnimationEffectReadonly,
|
||||
mTarget)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_TRACE_BEGIN_INHERITED(KeyframeEffectReadOnly,
|
||||
AnimationEffectReadOnly)
|
||||
NS_IMPL_CYCLE_COLLECTION_TRACE_BEGIN_INHERITED(KeyframeEffectReadonly,
|
||||
AnimationEffectReadonly)
|
||||
NS_IMPL_CYCLE_COLLECTION_TRACE_END
|
||||
|
||||
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION_INHERITED(KeyframeEffectReadOnly)
|
||||
NS_INTERFACE_MAP_END_INHERITING(AnimationEffectReadOnly)
|
||||
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION_INHERITED(KeyframeEffectReadonly)
|
||||
NS_INTERFACE_MAP_END_INHERITING(AnimationEffectReadonly)
|
||||
|
||||
NS_IMPL_ADDREF_INHERITED(KeyframeEffectReadOnly, AnimationEffectReadOnly)
|
||||
NS_IMPL_RELEASE_INHERITED(KeyframeEffectReadOnly, AnimationEffectReadOnly)
|
||||
NS_IMPL_ADDREF_INHERITED(KeyframeEffectReadonly, AnimationEffectReadonly)
|
||||
NS_IMPL_RELEASE_INHERITED(KeyframeEffectReadonly, AnimationEffectReadonly)
|
||||
|
||||
JSObject*
|
||||
KeyframeEffectReadOnly::WrapObject(JSContext* aCx,
|
||||
KeyframeEffectReadonly::WrapObject(JSContext* aCx,
|
||||
JS::Handle<JSObject*> aGivenProto)
|
||||
{
|
||||
return KeyframeEffectReadOnlyBinding::Wrap(aCx, this, aGivenProto);
|
||||
return KeyframeEffectReadonlyBinding::Wrap(aCx, this, aGivenProto);
|
||||
}
|
||||
|
||||
void
|
||||
KeyframeEffectReadOnly::SetParentTime(Nullable<TimeDuration> aParentTime)
|
||||
KeyframeEffectReadonly::SetParentTime(Nullable<TimeDuration> aParentTime)
|
||||
{
|
||||
mParentTime = aParentTime;
|
||||
}
|
||||
|
||||
ComputedTiming
|
||||
KeyframeEffectReadOnly::GetComputedTimingAt(
|
||||
KeyframeEffectReadonly::GetComputedTimingAt(
|
||||
const Nullable<TimeDuration>& aLocalTime,
|
||||
const AnimationTiming& aTiming)
|
||||
{
|
||||
@ -217,7 +217,7 @@ KeyframeEffectReadOnly::GetComputedTimingAt(
|
||||
}
|
||||
|
||||
StickyTimeDuration
|
||||
KeyframeEffectReadOnly::ActiveDuration(const AnimationTiming& aTiming)
|
||||
KeyframeEffectReadonly::ActiveDuration(const AnimationTiming& aTiming)
|
||||
{
|
||||
if (aTiming.mIterationCount == mozilla::PositiveInfinity<float>()) {
|
||||
// An animation that repeats forever has an infinite active duration
|
||||
@ -234,7 +234,7 @@ KeyframeEffectReadOnly::ActiveDuration(const AnimationTiming& aTiming)
|
||||
|
||||
// http://w3c.github.io/web-animations/#in-play
|
||||
bool
|
||||
KeyframeEffectReadOnly::IsInPlay(const Animation& aAnimation) const
|
||||
KeyframeEffectReadonly::IsInPlay(const Animation& aAnimation) const
|
||||
{
|
||||
if (IsFinishedTransition() ||
|
||||
aAnimation.PlayState() == AnimationPlayState::Finished) {
|
||||
@ -246,7 +246,7 @@ KeyframeEffectReadOnly::IsInPlay(const Animation& aAnimation) const
|
||||
|
||||
// http://w3c.github.io/web-animations/#current
|
||||
bool
|
||||
KeyframeEffectReadOnly::IsCurrent(const Animation& aAnimation) const
|
||||
KeyframeEffectReadonly::IsCurrent(const Animation& aAnimation) const
|
||||
{
|
||||
if (IsFinishedTransition() ||
|
||||
aAnimation.PlayState() == AnimationPlayState::Finished) {
|
||||
@ -259,7 +259,7 @@ KeyframeEffectReadOnly::IsCurrent(const Animation& aAnimation) const
|
||||
}
|
||||
|
||||
bool
|
||||
KeyframeEffectReadOnly::IsInEffect() const
|
||||
KeyframeEffectReadonly::IsInEffect() const
|
||||
{
|
||||
if (IsFinishedTransition()) {
|
||||
return false;
|
||||
@ -270,7 +270,7 @@ KeyframeEffectReadOnly::IsInEffect() const
|
||||
}
|
||||
|
||||
const AnimationProperty*
|
||||
KeyframeEffectReadOnly::GetAnimationOfProperty(nsCSSProperty aProperty) const
|
||||
KeyframeEffectReadonly::GetAnimationOfProperty(nsCSSProperty aProperty) const
|
||||
{
|
||||
for (size_t propIdx = 0, propEnd = mProperties.Length();
|
||||
propIdx != propEnd; ++propIdx) {
|
||||
@ -286,7 +286,7 @@ KeyframeEffectReadOnly::GetAnimationOfProperty(nsCSSProperty aProperty) const
|
||||
}
|
||||
|
||||
bool
|
||||
KeyframeEffectReadOnly::HasAnimationOfProperties(
|
||||
KeyframeEffectReadonly::HasAnimationOfProperties(
|
||||
const nsCSSProperty* aProperties,
|
||||
size_t aPropertyCount) const
|
||||
{
|
||||
@ -299,7 +299,7 @@ KeyframeEffectReadOnly::HasAnimationOfProperties(
|
||||
}
|
||||
|
||||
void
|
||||
KeyframeEffectReadOnly::ComposeStyle(
|
||||
KeyframeEffectReadonly::ComposeStyle(
|
||||
nsRefPtr<css::AnimValuesStyleRule>& aStyleRule,
|
||||
nsCSSPropertySet& aSetProperties)
|
||||
{
|
||||
|
@ -15,7 +15,7 @@
|
||||
#include "mozilla/StickyTimeDuration.h"
|
||||
#include "mozilla/StyleAnimationValue.h"
|
||||
#include "mozilla/TimeStamp.h"
|
||||
#include "mozilla/dom/AnimationEffectReadOnly.h"
|
||||
#include "mozilla/dom/AnimationEffectReadonly.h"
|
||||
#include "mozilla/dom/Element.h"
|
||||
#include "mozilla/dom/Nullable.h"
|
||||
#include "nsSMILKeySpline.h"
|
||||
@ -185,15 +185,15 @@ struct ElementPropertyTransition;
|
||||
|
||||
namespace dom {
|
||||
|
||||
class KeyframeEffectReadOnly : public AnimationEffectReadOnly
|
||||
class KeyframeEffectReadonly : public AnimationEffectReadonly
|
||||
{
|
||||
public:
|
||||
KeyframeEffectReadOnly(nsIDocument* aDocument,
|
||||
KeyframeEffectReadonly(nsIDocument* aDocument,
|
||||
Element* aTarget,
|
||||
nsCSSPseudoElements::Type aPseudoType,
|
||||
const AnimationTiming &aTiming,
|
||||
const nsSubstring& aName)
|
||||
: AnimationEffectReadOnly(aDocument)
|
||||
: AnimationEffectReadonly(aDocument)
|
||||
, mTarget(aTarget)
|
||||
, mTiming(aTiming)
|
||||
, mName(aName)
|
||||
@ -204,8 +204,8 @@ public:
|
||||
}
|
||||
|
||||
NS_DECL_ISUPPORTS_INHERITED
|
||||
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS_INHERITED(KeyframeEffectReadOnly,
|
||||
AnimationEffectReadOnly)
|
||||
NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS_INHERITED(KeyframeEffectReadonly,
|
||||
AnimationEffectReadonly)
|
||||
|
||||
virtual JSObject* WrapObject(JSContext* aCx,
|
||||
JS::Handle<JSObject*> aGivenProto) override;
|
||||
@ -215,7 +215,7 @@ public:
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
// KeyframeEffectReadOnly interface
|
||||
// KeyframeEffectReadonly interface
|
||||
Element* GetTarget() const {
|
||||
// Currently we only implement Element.getAnimations() which only
|
||||
// returns animations targetting Elements so this should never
|
||||
@ -332,7 +332,7 @@ public:
|
||||
nsCSSPropertySet& aSetProperties);
|
||||
|
||||
protected:
|
||||
virtual ~KeyframeEffectReadOnly() { }
|
||||
virtual ~KeyframeEffectReadonly() { }
|
||||
|
||||
nsCOMPtr<Element> mTarget;
|
||||
Nullable<TimeDuration> mParentTime;
|
||||
|
@ -9,7 +9,7 @@ MOCHITEST_CHROME_MANIFESTS += ['test/chrome.ini']
|
||||
|
||||
EXPORTS.mozilla.dom += [
|
||||
'Animation.h',
|
||||
'AnimationEffectReadOnly.h',
|
||||
'AnimationEffectReadonly.h',
|
||||
'AnimationTimeline.h',
|
||||
'DocumentTimeline.h',
|
||||
'KeyframeEffect.h',
|
||||
@ -22,7 +22,7 @@ EXPORTS.mozilla += [
|
||||
|
||||
UNIFIED_SOURCES += [
|
||||
'Animation.cpp',
|
||||
'AnimationEffectReadOnly.cpp',
|
||||
'AnimationEffectReadonly.cpp',
|
||||
'AnimationTimeline.cpp',
|
||||
'DocumentTimeline.cpp',
|
||||
'KeyframeEffect.cpp',
|
||||
|
@ -345,7 +345,7 @@ void
|
||||
nsAnimationReceiver::RecordAnimationMutation(Animation* aAnimation,
|
||||
AnimationMutation aMutationType)
|
||||
{
|
||||
KeyframeEffectReadOnly* effect = aAnimation->GetEffect();
|
||||
KeyframeEffectReadonly* effect = aAnimation->GetEffect();
|
||||
if (!effect) {
|
||||
return;
|
||||
}
|
||||
|
@ -218,7 +218,7 @@ nsNodeUtils::ContentRemoved(nsINode* aContainer,
|
||||
static inline Element*
|
||||
GetTarget(Animation* aAnimation)
|
||||
{
|
||||
KeyframeEffectReadOnly* effect = aAnimation->GetEffect();
|
||||
KeyframeEffectReadonly* effect = aAnimation->GetEffect();
|
||||
if (!effect) {
|
||||
return nullptr;
|
||||
}
|
||||
|
@ -88,7 +88,7 @@ DOMInterfaces = {
|
||||
'concrete': False
|
||||
},
|
||||
|
||||
'AnimationEffectReadOnly': {
|
||||
'AnimationEffectReadonly': {
|
||||
'concrete': False
|
||||
},
|
||||
|
||||
|
@ -132,7 +132,7 @@ var interfaceNamesInGlobalScope =
|
||||
// IMPORTANT: Do not change this list without review from a DOM peer!
|
||||
{name: "Animation", pref: "dom.animations-api.core.enabled"},
|
||||
// IMPORTANT: Do not change this list without review from a DOM peer!
|
||||
{name: "AnimationEffectReadOnly", pref: "dom.animations-api.core.enabled"},
|
||||
{name: "AnimationEffectReadonly", pref: "dom.animations-api.core.enabled"},
|
||||
// IMPORTANT: Do not change this list without review from a DOM peer!
|
||||
"AnimationEvent",
|
||||
// IMPORTANT: Do not change this list without review from a DOM peer!
|
||||
@ -651,7 +651,7 @@ var interfaceNamesInGlobalScope =
|
||||
// IMPORTANT: Do not change this list without review from a DOM peer!
|
||||
"KeyboardEvent",
|
||||
// IMPORTANT: Do not change this list without review from a DOM peer!
|
||||
{name: "KeyframeEffectReadOnly", pref: "dom.animations-api.core.enabled"},
|
||||
{name: "KeyframeEffectReadonly", pref: "dom.animations-api.core.enabled"},
|
||||
// IMPORTANT: Do not change this list without review from a DOM peer!
|
||||
"LocalMediaStream",
|
||||
// IMPORTANT: Do not change this list without review from a DOM peer!
|
||||
|
@ -16,7 +16,7 @@ enum AnimationPlayState { "idle", "pending", "running", "paused", "finished" };
|
||||
interface Animation {
|
||||
// Bug 1049975: Make 'effect' writeable
|
||||
[Pure]
|
||||
readonly attribute AnimationEffectReadOnly? effect;
|
||||
readonly attribute AnimationEffectReadonly? effect;
|
||||
readonly attribute AnimationTimeline timeline;
|
||||
[BinaryName="startTimeAsDouble"]
|
||||
attribute double? startTime;
|
||||
|
@ -11,8 +11,8 @@
|
||||
*/
|
||||
|
||||
[Func="nsDocument::IsWebAnimationsEnabled"]
|
||||
interface AnimationEffectReadOnly {
|
||||
interface AnimationEffectReadonly {
|
||||
// Not yet implemented:
|
||||
// readonly attribute AnimationEffectTimingReadOnly timing;
|
||||
// readonly attribute AnimationEffectTimingReadonly timing;
|
||||
// readonly attribute ComputedTimingProperties computedTiming;
|
||||
};
|
||||
|
18
dom/webidl/AnimationEffectReadonly.webidl
Normal file
18
dom/webidl/AnimationEffectReadonly.webidl
Normal file
@ -0,0 +1,18 @@
|
||||
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
||||
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||
* License, v. 2.0. If a copy of the MPL was not distributed with this file,
|
||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
*
|
||||
* The origin of this IDL file is
|
||||
* http://w3c.github.io/web-animations/#animationeffectreadonly
|
||||
*
|
||||
* Copyright © 2015 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
|
||||
* liability, trademark and document use rules apply.
|
||||
*/
|
||||
|
||||
[Func="nsDocument::IsWebAnimationsEnabled"]
|
||||
interface AnimationEffectReadonly {
|
||||
// Not yet implemented:
|
||||
// readonly attribute AnimationEffectTimingReadonly timing;
|
||||
// readonly attribute ComputedTimingProperties computedTiming;
|
||||
};
|
@ -12,7 +12,7 @@
|
||||
|
||||
[HeaderFile="mozilla/dom/KeyframeEffect.h",
|
||||
Func="nsDocument::IsWebAnimationsEnabled"]
|
||||
interface KeyframeEffectReadOnly : AnimationEffectReadOnly {
|
||||
interface KeyframeEffectReadonly : AnimationEffectReadonly {
|
||||
readonly attribute Element? target;
|
||||
readonly attribute DOMString name;
|
||||
// Not yet implemented:
|
||||
|
@ -23,7 +23,7 @@ WEBIDL_FILES = [
|
||||
'AnalyserNode.webidl',
|
||||
'Animatable.webidl',
|
||||
'Animation.webidl',
|
||||
'AnimationEffectReadOnly.webidl',
|
||||
'AnimationEffectReadonly.webidl',
|
||||
'AnimationEvent.webidl',
|
||||
'AnimationTimeline.webidl',
|
||||
'AnonymousContent.webidl',
|
||||
|
@ -13,7 +13,7 @@
|
||||
#include "gfxPoint.h" // for gfxPoint, gfxSize
|
||||
#include "mozilla/StyleAnimationValue.h" // for StyleAnimationValue, etc
|
||||
#include "mozilla/WidgetUtils.h" // for ComputeTransformForRotation
|
||||
#include "mozilla/dom/KeyframeEffect.h" // for KeyframeEffectReadOnly
|
||||
#include "mozilla/dom/KeyframeEffect.h" // for KeyframeEffectReadonly
|
||||
#include "mozilla/gfx/BaseRect.h" // for BaseRect
|
||||
#include "mozilla/gfx/Point.h" // for RoundedToInt, PointTyped
|
||||
#include "mozilla/gfx/Rect.h" // for RoundedToInt, RectTyped
|
||||
@ -474,7 +474,7 @@ SampleAnimations(Layer* aLayer, TimeStamp aPoint)
|
||||
timing.mFillMode = NS_STYLE_ANIMATION_FILL_MODE_BOTH;
|
||||
|
||||
ComputedTiming computedTiming =
|
||||
dom::KeyframeEffectReadOnly::GetComputedTimingAt(
|
||||
dom::KeyframeEffectReadonly::GetComputedTimingAt(
|
||||
Nullable<TimeDuration>(elapsedDuration), timing);
|
||||
|
||||
MOZ_ASSERT(0.0 <= computedTiming.mTimeFraction &&
|
||||
|
@ -426,7 +426,7 @@ AddAnimationsForProperty(nsIFrame* aFrame, nsCSSProperty aProperty,
|
||||
if (!anim->IsPlaying()) {
|
||||
continue;
|
||||
}
|
||||
dom::KeyframeEffectReadOnly* effect = anim->GetEffect();
|
||||
dom::KeyframeEffectReadonly* effect = anim->GetEffect();
|
||||
MOZ_ASSERT(effect, "A playing animation should have an effect");
|
||||
const AnimationProperty* property =
|
||||
effect->GetAnimationOfProperty(aProperty);
|
||||
|
@ -505,7 +505,7 @@ GetMinAndMaxScaleForAnimationProperty(nsIContent* aContent,
|
||||
if (!anim->GetEffect() || anim->GetEffect()->IsFinishedTransition()) {
|
||||
continue;
|
||||
}
|
||||
dom::KeyframeEffectReadOnly* effect = anim->GetEffect();
|
||||
dom::KeyframeEffectReadonly* effect = anim->GetEffect();
|
||||
for (size_t propIdx = effect->Properties().Length(); propIdx-- != 0; ) {
|
||||
AnimationProperty& prop = effect->Properties()[propIdx];
|
||||
if (prop.mProperty == eCSSProperty_transform) {
|
||||
|
@ -30,7 +30,7 @@
|
||||
|
||||
using mozilla::layers::Layer;
|
||||
using mozilla::dom::Animation;
|
||||
using mozilla::dom::KeyframeEffectReadOnly;
|
||||
using mozilla::dom::KeyframeEffectReadonly;
|
||||
|
||||
namespace mozilla {
|
||||
|
||||
@ -601,7 +601,7 @@ AnimationCollection::CanPerformOnCompositorThread(
|
||||
continue;
|
||||
}
|
||||
|
||||
const KeyframeEffectReadOnly* effect = anim->GetEffect();
|
||||
const KeyframeEffectReadonly* effect = anim->GetEffect();
|
||||
MOZ_ASSERT(effect, "A playing animation should have an effect");
|
||||
|
||||
for (size_t propIdx = 0, propEnd = effect->Properties().Length();
|
||||
@ -620,7 +620,7 @@ AnimationCollection::CanPerformOnCompositorThread(
|
||||
continue;
|
||||
}
|
||||
|
||||
const KeyframeEffectReadOnly* effect = anim->GetEffect();
|
||||
const KeyframeEffectReadonly* effect = anim->GetEffect();
|
||||
MOZ_ASSERT(effect, "A playing animation should have an effect");
|
||||
|
||||
existsProperty = existsProperty || effect->Properties().Length() > 0;
|
||||
@ -673,7 +673,7 @@ bool
|
||||
AnimationCollection::HasAnimationOfProperty(nsCSSProperty aProperty) const
|
||||
{
|
||||
for (size_t animIdx = mAnimations.Length(); animIdx-- != 0; ) {
|
||||
const KeyframeEffectReadOnly* effect = mAnimations[animIdx]->GetEffect();
|
||||
const KeyframeEffectReadonly* effect = mAnimations[animIdx]->GetEffect();
|
||||
if (effect && effect->HasAnimationOfProperty(aProperty) &&
|
||||
!effect->IsFinishedTransition()) {
|
||||
return true;
|
||||
@ -922,7 +922,7 @@ AnimationCollection::HasCurrentAnimationsForProperties(
|
||||
{
|
||||
for (size_t animIdx = mAnimations.Length(); animIdx-- != 0; ) {
|
||||
const Animation& anim = *mAnimations[animIdx];
|
||||
const KeyframeEffectReadOnly* effect = anim.GetEffect();
|
||||
const KeyframeEffectReadonly* effect = anim.GetEffect();
|
||||
if (effect &&
|
||||
effect->IsCurrent(anim) &&
|
||||
effect->HasAnimationOfProperties(aProperties, aPropertyCount)) {
|
||||
|
@ -26,7 +26,7 @@ using namespace mozilla;
|
||||
using namespace mozilla::css;
|
||||
using mozilla::dom::Animation;
|
||||
using mozilla::dom::AnimationPlayState;
|
||||
using mozilla::dom::KeyframeEffectReadOnly;
|
||||
using mozilla::dom::KeyframeEffectReadonly;
|
||||
using mozilla::CSSAnimation;
|
||||
|
||||
mozilla::dom::Promise*
|
||||
@ -352,8 +352,8 @@ nsAnimationManager::CheckAnimationRule(nsStyleContext* aStyleContext,
|
||||
// Update the old from the new so we can keep the original object
|
||||
// identity (and any expando properties attached to it).
|
||||
if (oldAnim->GetEffect() && newAnim->GetEffect()) {
|
||||
KeyframeEffectReadOnly* oldEffect = oldAnim->GetEffect();
|
||||
KeyframeEffectReadOnly* newEffect = newAnim->GetEffect();
|
||||
KeyframeEffectReadonly* oldEffect = oldAnim->GetEffect();
|
||||
KeyframeEffectReadonly* newEffect = newAnim->GetEffect();
|
||||
animationChanged =
|
||||
oldEffect->Timing() != newEffect->Timing() ||
|
||||
oldEffect->Properties() != newEffect->Properties();
|
||||
@ -526,8 +526,8 @@ nsAnimationManager::BuildAnimations(nsStyleContext* aStyleContext,
|
||||
timing.mDirection = src.GetDirection();
|
||||
timing.mFillMode = src.GetFillMode();
|
||||
|
||||
nsRefPtr<KeyframeEffectReadOnly> destEffect =
|
||||
new KeyframeEffectReadOnly(mPresContext->Document(), aTarget,
|
||||
nsRefPtr<KeyframeEffectReadonly> destEffect =
|
||||
new KeyframeEffectReadonly(mPresContext->Document(), aTarget,
|
||||
aStyleContext->GetPseudoType(), timing,
|
||||
src.GetName());
|
||||
dest->SetEffect(destEffect);
|
||||
@ -754,7 +754,7 @@ nsAnimationManager::UpdateCascadeResults(
|
||||
for (size_t animIdx = aElementAnimations->mAnimations.Length();
|
||||
animIdx-- != 0; ) {
|
||||
const Animation* anim = aElementAnimations->mAnimations[animIdx];
|
||||
const KeyframeEffectReadOnly* effect = anim->GetEffect();
|
||||
const KeyframeEffectReadonly* effect = anim->GetEffect();
|
||||
if (!effect) {
|
||||
continue;
|
||||
}
|
||||
@ -802,7 +802,7 @@ nsAnimationManager::UpdateCascadeResults(
|
||||
animIdx-- != 0; ) {
|
||||
CSSAnimation* anim =
|
||||
aElementAnimations->mAnimations[animIdx]->AsCSSAnimation();
|
||||
KeyframeEffectReadOnly* effect = anim->GetEffect();
|
||||
KeyframeEffectReadonly* effect = anim->GetEffect();
|
||||
|
||||
anim->mInEffectForCascadeResults = anim->IsInEffect();
|
||||
|
||||
|
@ -34,7 +34,7 @@
|
||||
using mozilla::TimeStamp;
|
||||
using mozilla::TimeDuration;
|
||||
using mozilla::dom::Animation;
|
||||
using mozilla::dom::KeyframeEffectReadOnly;
|
||||
using mozilla::dom::KeyframeEffectReadonly;
|
||||
|
||||
using namespace mozilla;
|
||||
using namespace mozilla::css;
|
||||
@ -46,7 +46,7 @@ ElementPropertyTransition::Name() const
|
||||
const_cast<ElementPropertyTransition*>(this)->mName =
|
||||
NS_ConvertUTF8toUTF16(nsCSSProps::GetStringValue(TransitionProperty()));
|
||||
}
|
||||
return dom::KeyframeEffectReadOnly::Name();
|
||||
return dom::KeyframeEffectReadonly::Name();
|
||||
}
|
||||
|
||||
double
|
||||
@ -321,7 +321,7 @@ nsTransitionManager::StyleContextChanged(dom::Element *aElement,
|
||||
do {
|
||||
--i;
|
||||
Animation* anim = animations[i];
|
||||
dom::KeyframeEffectReadOnly* effect = anim->GetEffect();
|
||||
dom::KeyframeEffectReadonly* effect = anim->GetEffect();
|
||||
MOZ_ASSERT(effect && effect->Properties().Length() == 1,
|
||||
"Should have one animation property for a transition");
|
||||
MOZ_ASSERT(effect && effect->Properties()[0].mSegments.Length() == 1,
|
||||
@ -633,7 +633,7 @@ nsTransitionManager::PruneCompletedTransitions(mozilla::dom::Element* aElement,
|
||||
do {
|
||||
--i;
|
||||
Animation* anim = animations[i];
|
||||
dom::KeyframeEffectReadOnly* effect = anim->GetEffect();
|
||||
dom::KeyframeEffectReadonly* effect = anim->GetEffect();
|
||||
|
||||
if (!effect->IsFinishedTransition()) {
|
||||
continue;
|
||||
|
@ -29,13 +29,13 @@ struct StyleTransition;
|
||||
|
||||
namespace mozilla {
|
||||
|
||||
struct ElementPropertyTransition : public dom::KeyframeEffectReadOnly
|
||||
struct ElementPropertyTransition : public dom::KeyframeEffectReadonly
|
||||
{
|
||||
ElementPropertyTransition(nsIDocument* aDocument,
|
||||
dom::Element* aTarget,
|
||||
nsCSSPseudoElements::Type aPseudoType,
|
||||
const AnimationTiming &aTiming)
|
||||
: dom::KeyframeEffectReadOnly(aDocument, aTarget, aPseudoType,
|
||||
: dom::KeyframeEffectReadonly(aDocument, aTarget, aPseudoType,
|
||||
aTiming, EmptyString())
|
||||
{ }
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user