OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2003 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2003 Lars Knoll (knoll@kde.org) |
3 * Copyright (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 3 * Copyright (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. | 4 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. |
5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> | 5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> |
6 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> | 6 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> |
7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 7 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
8 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. | 8 * Copyright (C) 2012 Adobe Systems Incorporated. All rights reserved. |
9 * Copyright (C) 2012 Intel Corporation. All rights reserved. | 9 * Copyright (C) 2012 Intel Corporation. All rights reserved. |
10 * | 10 * |
(...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
240 value->unit = (unitflags & FLength) ? CSSPrimitiveValue::CSS_PX : CS
SPrimitiveValue::CSS_DEG; | 240 value->unit = (unitflags & FLength) ? CSSPrimitiveValue::CSS_PX : CS
SPrimitiveValue::CSS_DEG; |
241 return true; | 241 return true; |
242 } | 242 } |
243 if ((unitflags & FInteger) && value->isInt) | 243 if ((unitflags & FInteger) && value->isInt) |
244 return true; | 244 return true; |
245 if ((unitflags & FPositiveInteger) && value->isInt && value->fValue > 0) | 245 if ((unitflags & FPositiveInteger) && value->isInt && value->fValue > 0) |
246 return true; | 246 return true; |
247 return false; | 247 return false; |
248 case CSSPrimitiveValue::CSS_PERCENTAGE: | 248 case CSSPrimitiveValue::CSS_PERCENTAGE: |
249 return unitflags & FPercent; | 249 return unitflags & FPercent; |
250 // TODO(timloh): Restrict usage of __qem to UA sheets | |
251 case CSSParserValue::Q_EMS: | 250 case CSSParserValue::Q_EMS: |
| 251 if (cssParserMode != UASheetMode) |
| 252 return false; |
| 253 /* fallthrough intentional */ |
252 case CSSPrimitiveValue::CSS_EMS: | 254 case CSSPrimitiveValue::CSS_EMS: |
253 case CSSPrimitiveValue::CSS_REMS: | 255 case CSSPrimitiveValue::CSS_REMS: |
254 case CSSPrimitiveValue::CSS_CHS: | 256 case CSSPrimitiveValue::CSS_CHS: |
255 case CSSPrimitiveValue::CSS_EXS: | 257 case CSSPrimitiveValue::CSS_EXS: |
256 case CSSPrimitiveValue::CSS_PX: | 258 case CSSPrimitiveValue::CSS_PX: |
257 case CSSPrimitiveValue::CSS_CM: | 259 case CSSPrimitiveValue::CSS_CM: |
258 case CSSPrimitiveValue::CSS_MM: | 260 case CSSPrimitiveValue::CSS_MM: |
259 case CSSPrimitiveValue::CSS_IN: | 261 case CSSPrimitiveValue::CSS_IN: |
260 case CSSPrimitiveValue::CSS_PT: | 262 case CSSPrimitiveValue::CSS_PT: |
261 case CSSPrimitiveValue::CSS_PC: | 263 case CSSPrimitiveValue::CSS_PC: |
(...skipping 8167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8429 } | 8431 } |
8430 } | 8432 } |
8431 | 8433 |
8432 if (!list->length()) | 8434 if (!list->length()) |
8433 return nullptr; | 8435 return nullptr; |
8434 | 8436 |
8435 return list.release(); | 8437 return list.release(); |
8436 } | 8438 } |
8437 | 8439 |
8438 } // namespace blink | 8440 } // namespace blink |
OLD | NEW |