From eb4999573733a805e9117a40b10151c9308929bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= Date: Mon, 30 Jul 2018 18:04:05 +0200 Subject: [PATCH] style: Convert GetStringValue to use Servo. And remove gPropertyTable / kCSSRawProperties while at it. Differential Revision: https://phabricator.services.mozilla.com/D2516 --- components/style/properties/properties.mako.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/components/style/properties/properties.mako.rs b/components/style/properties/properties.mako.rs index 27458cf67c4..809820eae07 100644 --- a/components/style/properties/properties.mako.rs +++ b/components/style/properties/properties.mako.rs @@ -427,9 +427,10 @@ impl NonCustomPropertyId { unsafe { ::std::mem::transmute(self.0 as i32) } } + /// Convert an `nsCSSPropertyID` into a `NonCustomPropertyId`. #[cfg(feature = "gecko")] #[inline] - fn from_nscsspropertyid(prop: nsCSSPropertyID) -> Result { + pub fn from_nscsspropertyid(prop: nsCSSPropertyID) -> Result { let prop = prop as i32; if prop < 0 { return Err(()); @@ -443,7 +444,7 @@ impl NonCustomPropertyId { /// Get the property name. #[inline] - fn name(self) -> &'static str { + pub fn name(self) -> &'static str { static MAP: [&'static str; ${len(data.longhands) + len(data.shorthands) + len(data.all_aliases())}] = [ % for property in data.longhands + data.shorthands + data.all_aliases(): "${property.name}",