mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
Don't fill out deficient animation/transition property values in the style struct
This commit is contained in:
parent
9c05bc92f8
commit
9b6c5da98f
1 changed files with 6 additions and 6 deletions
|
@ -2948,8 +2948,8 @@ fn static_assert() {
|
|||
let count = other.gecko.m${type.capitalize()}${gecko_ffi_name}Count;
|
||||
self.gecko.m${type.capitalize()}${gecko_ffi_name}Count = count;
|
||||
|
||||
let iter = self.gecko.m${type.capitalize()}s.iter_mut().zip(
|
||||
other.gecko.m${type.capitalize()}s.iter().take(count as usize).cycle()
|
||||
let iter = self.gecko.m${type.capitalize()}s.iter_mut().take(count as usize).zip(
|
||||
other.gecko.m${type.capitalize()}s.iter()
|
||||
);
|
||||
|
||||
for (ours, others) in iter {
|
||||
|
@ -2982,7 +2982,7 @@ fn static_assert() {
|
|||
self.gecko.m${type.capitalize()}s.ensure_len(input_len);
|
||||
|
||||
self.gecko.m${type.capitalize()}${gecko_ffi_name}Count = input_len as u32;
|
||||
for (gecko, servo) in self.gecko.m${type.capitalize()}s.iter_mut().zip(v.cycle()) {
|
||||
for (gecko, servo) in self.gecko.m${type.capitalize()}s.iter_mut().take(input_len as usize).zip(v) {
|
||||
gecko.m${gecko_ffi_name} = servo.seconds() * 1000.;
|
||||
}
|
||||
}
|
||||
|
@ -3007,7 +3007,7 @@ fn static_assert() {
|
|||
self.gecko.m${type.capitalize()}s.ensure_len(input_len);
|
||||
|
||||
self.gecko.m${type.capitalize()}TimingFunctionCount = input_len as u32;
|
||||
for (gecko, servo) in self.gecko.m${type.capitalize()}s.iter_mut().zip(v.cycle()) {
|
||||
for (gecko, servo) in self.gecko.m${type.capitalize()}s.iter_mut().take(input_len as usize).zip(v) {
|
||||
gecko.mTimingFunction = servo.into();
|
||||
}
|
||||
}
|
||||
|
@ -3064,7 +3064,7 @@ fn static_assert() {
|
|||
|
||||
self.gecko.mAnimation${gecko_ffi_name}Count = input_len as u32;
|
||||
|
||||
for (gecko, servo) in self.gecko.mAnimations.iter_mut().zip(v.cycle()) {
|
||||
for (gecko, servo) in self.gecko.mAnimations.iter_mut().take(input_len as usize).zip(v) {
|
||||
let result = match servo {
|
||||
% for value in keyword.gecko_values():
|
||||
Keyword::${to_camel_case(value)} =>
|
||||
|
@ -3465,7 +3465,7 @@ fn static_assert() {
|
|||
self.gecko.mAnimations.ensure_len(input_len);
|
||||
|
||||
self.gecko.mAnimationIterationCountCount = input_len as u32;
|
||||
for (gecko, servo) in self.gecko.mAnimations.iter_mut().zip(v.cycle()) {
|
||||
for (gecko, servo) in self.gecko.mAnimations.iter_mut().take(input_len as usize).zip(v) {
|
||||
match servo {
|
||||
AnimationIterationCount::Number(n) => gecko.mIterationCount = n,
|
||||
AnimationIterationCount::Infinite => gecko.mIterationCount = f32::INFINITY,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue