diff options
author | Nazım Can Altınova <canaltinova@gmail.com> | 2017-08-16 12:58:40 -0700 |
---|---|---|
committer | Nazım Can Altınova <canaltinova@gmail.com> | 2017-08-16 13:23:14 -0700 |
commit | 6893446b710e8c6db47a5eb71fa12771eaa32267 (patch) | |
tree | fed3ef5e0d3aede7300be1d309f4f6993d3d4961 /components/script/dom/cssstyledeclaration.rs | |
parent | 4d10d39e8fe841c5fe2ac58da2daaa13c10c140e (diff) | |
download | servo-6893446b710e8c6db47a5eb71fa12771eaa32267.tar.gz servo-6893446b710e8c6db47a5eb71fa12771eaa32267.zip |
Add a pref checking mechanism for alias properties
Diffstat (limited to 'components/script/dom/cssstyledeclaration.rs')
-rw-r--r-- | components/script/dom/cssstyledeclaration.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/components/script/dom/cssstyledeclaration.rs b/components/script/dom/cssstyledeclaration.rs index ddf085b3491..f87c184ef63 100644 --- a/components/script/dom/cssstyledeclaration.rs +++ b/components/script/dom/cssstyledeclaration.rs @@ -296,7 +296,7 @@ impl CSSStyleDeclarationMethods for CSSStyleDeclaration { // https://dev.w3.org/csswg/cssom/#dom-cssstyledeclaration-getpropertyvalue fn GetPropertyValue(&self, property: DOMString) -> DOMString { - let id = if let Ok(id) = PropertyId::parse(&property) { + let id = if let Ok(id) = PropertyId::parse(&property, None) { id } else { // Unkwown property @@ -307,7 +307,7 @@ impl CSSStyleDeclarationMethods for CSSStyleDeclaration { // https://dev.w3.org/csswg/cssom/#dom-cssstyledeclaration-getpropertypriority fn GetPropertyPriority(&self, property: DOMString) -> DOMString { - let id = if let Ok(id) = PropertyId::parse(&property) { + let id = if let Ok(id) = PropertyId::parse(&property, None) { id } else { // Unkwown property @@ -331,7 +331,7 @@ impl CSSStyleDeclarationMethods for CSSStyleDeclaration { priority: DOMString) -> ErrorResult { // Step 3 - let id = if let Ok(id) = PropertyId::parse(&property) { + let id = if let Ok(id) = PropertyId::parse(&property, None) { id } else { // Unknown property @@ -348,7 +348,7 @@ impl CSSStyleDeclarationMethods for CSSStyleDeclaration { } // Step 2 & 3 - let id = match PropertyId::parse(&property) { + let id = match PropertyId::parse(&property, None) { Ok(id) => id, Err(..) => return Ok(()), // Unkwown property }; @@ -380,7 +380,7 @@ impl CSSStyleDeclarationMethods for CSSStyleDeclaration { return Err(Error::NoModificationAllowed); } - let id = if let Ok(id) = PropertyId::parse(&property) { + let id = if let Ok(id) = PropertyId::parse(&property, None) { id } else { // Unkwown property, cannot be there to remove. |