зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1232563 part 3 - Drop check for an empty set of properties when requesting restyles from KeyframeEffectReadOnly; r=heycam
This is because rather than simply requesting a throttled restyle when there were no properties, as of the previous patch, we no longer request a restyle at all in this case. We should be able to restore this optimization in bug 1235002 when we properly encapsulate the properties of a keyframe effect. --HG-- extra : rebase_source : 1774698e15178cf8f8295160b96adea8ca5a2ed2
This commit is contained in:
Родитель
55c934a957
Коммит
ba0280fd28
|
@ -164,8 +164,15 @@ KeyframeEffectReadOnly::NotifyAnimationTimingUpdated()
|
||||||
|
|
||||||
// Request restyle if necessary.
|
// Request restyle if necessary.
|
||||||
AnimationCollection* collection = GetCollection();
|
AnimationCollection* collection = GetCollection();
|
||||||
|
// Bug 1235002: We should skip requesting a restyle when mProperties is empty.
|
||||||
|
// However, currently we don't properly encapsulate mProperties so we can't
|
||||||
|
// detect when it changes. As a result, if we skip requesting restyles when
|
||||||
|
// mProperties is empty and we play an animation and *then* add properties to
|
||||||
|
// it (as we currently do when building CSS animations), we will fail to
|
||||||
|
// request a restyle at all. Since animations without properties are rare, we
|
||||||
|
// currently just request the restyle regardless of whether mProperties is
|
||||||
|
// empty or not.
|
||||||
if (collection &&
|
if (collection &&
|
||||||
!mProperties.IsEmpty() &&
|
|
||||||
inEffect) {
|
inEffect) {
|
||||||
// FIXME: Detect when the progress is not changing and don't request a
|
// FIXME: Detect when the progress is not changing and don't request a
|
||||||
// restyle in that case
|
// restyle in that case
|
||||||
|
|
Загрузка…
Ссылка в новой задаче