Add AnimationValueMap and expose it in FFI.

Current Gecko composes all of effects in the composite order at once.
We can put each computed value into this AnimationValueMap every time composing
an effect.
This commit is contained in:
Hiroyuki Ikezoe 2017-03-17 12:29:08 +09:00
parent ba18c14b91
commit 52bee9a4cf
6 changed files with 36 additions and 2 deletions

View file

@ -25,6 +25,7 @@ use properties::longhands::visibility::computed_value::T as Visibility;
use properties::longhands::z_index::computed_value::T as ZIndex;
#[cfg(feature = "gecko")] use properties::{PropertyDeclarationId, LonghandId};
use std::cmp;
#[cfg(feature = "gecko")] use std::collections::HashMap;
use std::fmt;
use style_traits::ToCss;
use super::ComputedValues;
@ -252,6 +253,12 @@ impl AnimatedProperty {
}
}
/// A collection of AnimationValue that were composed on an element.
/// This HashMap stores the values that are the last AnimationValue to be
/// composed for each TransitionProperty.
#[cfg(feature = "gecko")]
pub type AnimationValueMap = HashMap<TransitionProperty, AnimationValue>;
/// An enum to represent a single computed value belonging to an animated
/// property in order to be interpolated with another one. When interpolating,
/// both values need to belong to the same property.