| 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 3740 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3751 | 3751 |
| 3752 PassRefPtrWillBeRawPtr<CSSPrimitiveValue> CSSPropertyParser::parseGridBreadth(CS
SParserValue* currentValue) | 3752 PassRefPtrWillBeRawPtr<CSSPrimitiveValue> CSSPropertyParser::parseGridBreadth(CS
SParserValue* currentValue) |
| 3753 { | 3753 { |
| 3754 if (currentValue->id == CSSValueMinContent || currentValue->id == CSSValueMa
xContent || currentValue->id == CSSValueAuto) | 3754 if (currentValue->id == CSSValueMinContent || currentValue->id == CSSValueMa
xContent || currentValue->id == CSSValueAuto) |
| 3755 return cssValuePool().createIdentifierValue(currentValue->id); | 3755 return cssValuePool().createIdentifierValue(currentValue->id); |
| 3756 | 3756 |
| 3757 if (currentValue->unit() == CSSPrimitiveValue::UnitType::Fraction) { | 3757 if (currentValue->unit() == CSSPrimitiveValue::UnitType::Fraction) { |
| 3758 double flexValue = currentValue->fValue; | 3758 double flexValue = currentValue->fValue; |
| 3759 | 3759 |
| 3760 // Fractional unit is a non-negative dimension. | 3760 // Fractional unit is a non-negative dimension. |
| 3761 if (flexValue <= 0) | 3761 if (flexValue < 0) |
| 3762 return nullptr; | 3762 return nullptr; |
| 3763 | 3763 |
| 3764 return cssValuePool().createValue(flexValue, CSSPrimitiveValue::UnitType
::Fraction); | 3764 return cssValuePool().createValue(flexValue, CSSPrimitiveValue::UnitType
::Fraction); |
| 3765 } | 3765 } |
| 3766 | 3766 |
| 3767 if (!validUnit(currentValue, FNonNeg | FLength | FPercent)) | 3767 if (!validUnit(currentValue, FNonNeg | FLength | FPercent)) |
| 3768 return nullptr; | 3768 return nullptr; |
| 3769 | 3769 |
| 3770 return createPrimitiveNumericValue(currentValue); | 3770 return createPrimitiveNumericValue(currentValue); |
| 3771 } | 3771 } |
| (...skipping 4322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8094 } | 8094 } |
| 8095 } | 8095 } |
| 8096 | 8096 |
| 8097 if (!list->length()) | 8097 if (!list->length()) |
| 8098 return nullptr; | 8098 return nullptr; |
| 8099 | 8099 |
| 8100 return list.release(); | 8100 return list.release(); |
| 8101 } | 8101 } |
| 8102 | 8102 |
| 8103 } // namespace blink | 8103 } // namespace blink |
| OLD | NEW |