mirror of
https://github.com/servo/servo.git
synced 2025-08-17 11:25:35 +01:00
Rename AllowedNumericType to AllowedLengthType
This commit is contained in:
parent
5f6c27bb94
commit
12d46e7d01
3 changed files with 36 additions and 36 deletions
|
@ -9,7 +9,7 @@ use cssparser::{Parser, ToCss};
|
|||
use euclid::size::TypedSize2D;
|
||||
use std::ascii::AsciiExt;
|
||||
use std::fmt;
|
||||
use values::specified::AllowedNumericType;
|
||||
use values::specified::AllowedLengthType;
|
||||
|
||||
define_css_keyword_enum!(UserZoom:
|
||||
"zoom" => Zoom,
|
||||
|
@ -95,9 +95,9 @@ impl Zoom {
|
|||
use cssparser::Token;
|
||||
|
||||
match try!(input.next()) {
|
||||
Token::Percentage(ref value) if AllowedNumericType::NonNegative.is_ok(value.unit_value) =>
|
||||
Token::Percentage(ref value) if AllowedLengthType::NonNegative.is_ok(value.unit_value) =>
|
||||
Ok(Zoom::Percentage(value.unit_value)),
|
||||
Token::Number(ref value) if AllowedNumericType::NonNegative.is_ok(value.value) =>
|
||||
Token::Number(ref value) if AllowedLengthType::NonNegative.is_ok(value.value) =>
|
||||
Ok(Zoom::Number(value.value)),
|
||||
Token::Ident(ref value) if value.eq_ignore_ascii_case("auto") =>
|
||||
Ok(Zoom::Auto),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue