- From: Yves Lafon via cvs-syncmail <cvsmail@w3.org>
- Date: Thu, 30 Aug 2012 09:10:59 +0000
- To: www-validator-cvs@w3.org
Update of /sources/public/2002/css-validator/org/w3c/css/properties/css2 In directory hutz:/tmp/cvs-serv23620/css2 Modified Files: CssFontFamily.java Log Message: font family parsing was eating one extra ident Index: CssFontFamily.java =================================================================== RCS file: /sources/public/2002/css-validator/org/w3c/css/properties/css2/CssFontFamily.java,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- CssFontFamily.java 23 Aug 2012 14:53:38 -0000 1.2 +++ CssFontFamily.java 30 Aug 2012 09:10:57 -0000 1.3 @@ -9,6 +9,7 @@ import org.w3c.css.util.InvalidParamException; import org.w3c.css.values.CssExpression; import org.w3c.css.values.CssIdent; +import org.w3c.css.values.CssLayerList; import org.w3c.css.values.CssTypes; import org.w3c.css.values.CssValue; @@ -140,8 +141,8 @@ ArrayList<CssIdent> idval = new ArrayList<CssIdent>(); idval.add((CssIdent) val); // we add idents if separated by spaces... - expression.next(); while (op == SPACE && !expression.end()) { + expression.next(); op = expression.getOperator(); val = expression.getValue(); if (val.getType() == CssTypes.CSS_IDENT) { @@ -150,7 +151,6 @@ throw new InvalidParamException("value", val, getPropertyName(), ac); } - expression.next(); } checkExpression(ac, values, idval, check); break; @@ -165,7 +165,7 @@ } } checkValues(ac, values); - value = (values.size() > 1) ? values : values.get(0); + value = (values.size() > 1) ? new CssLayerList(values) : values.get(0); } public CssFontFamily(ApplContext ac, CssExpression expression)
Received on Thursday, 30 August 2012 09:11:05 UTC