Skip to content

Commit

Permalink
style: Remove code that is no longer called.
Browse files Browse the repository at this point in the history
Au revoir!

Bug: 1458814
Reviewed-by: hiro
MozReview-Commit-ID: DjqszUSIzXs
  • Loading branch information
emilio committed May 5, 2018
1 parent 5668812 commit 16815bf
Showing 1 changed file with 1 addition and 27 deletions.
28 changes: 1 addition & 27 deletions ports/geckolib/glue.rs
Expand Up @@ -73,7 +73,6 @@ use style::gecko_bindings::bindings::RawGeckoCSSPropertyIDListBorrowed;
use style::gecko_bindings::bindings::RawGeckoComputedKeyframeValuesListBorrowedMut;
use style::gecko_bindings::bindings::RawGeckoComputedTimingBorrowed;
use style::gecko_bindings::bindings::RawGeckoFontFaceRuleListBorrowedMut;
use style::gecko_bindings::bindings::RawGeckoServoAnimationValueListBorrowed;
use style::gecko_bindings::bindings::RawGeckoServoAnimationValueListBorrowedMut;
use style::gecko_bindings::bindings::RawGeckoServoStyleRuleListBorrowedMut;
use style::gecko_bindings::bindings::RawServoAnimationValueBorrowed;
Expand Down Expand Up @@ -129,7 +128,7 @@ use style::invalidation::element::restyle_hints;
use style::media_queries::{MediaList, parse_media_query_list};
use style::parser::{Parse, ParserContext, self};
use style::properties::{ComputedValues, DeclarationSource, Importance};
use style::properties::{LonghandId, LonghandIdSet, PropertyDeclaration, PropertyDeclarationBlock, PropertyId};
use style::properties::{LonghandId, LonghandIdSet, PropertyDeclarationBlock, PropertyId};
use style::properties::{PropertyDeclarationId, ShorthandId};
use style::properties::{SourcePropertyDeclaration, StyleBuilder};
use style::properties::{parse_one_declaration_into, parse_style_attribute};
Expand Down Expand Up @@ -708,31 +707,6 @@ pub extern "C" fn Servo_AnimationValue_Serialize(
debug_assert!(rv.is_ok());
}

#[no_mangle]
pub unsafe extern "C" fn Servo_Shorthand_AnimationValues_Serialize(
shorthand_property: nsCSSPropertyID,
values: RawGeckoServoAnimationValueListBorrowed,
buffer: *mut nsAString,
) {
let property_id = get_property_id_from_nscsspropertyid!(shorthand_property, ());
let shorthand = match property_id.as_shorthand() {
Ok(shorthand) => shorthand,
_ => return,
};

// Convert RawServoAnimationValue(s) into a vector of PropertyDeclaration
// so that we can use reference of the PropertyDeclaration without worrying
// about its lifetime. (longhands_to_css() expects &PropertyDeclaration
// iterator.)
let declarations: Vec<PropertyDeclaration> =
values.iter().map(|v| AnimationValue::as_arc(&&*v.mRawPtr).uncompute()).collect();

let _ = shorthand.longhands_to_css(
declarations.iter(),
&mut CssWriter::new(&mut *buffer),
);
}

#[no_mangle]
pub extern "C" fn Servo_AnimationValue_GetOpacity(
value: RawServoAnimationValueBorrowed,
Expand Down

0 comments on commit 16815bf

Please sign in to comment.