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 7087 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7098 if (context.allowFinalCommit()) { | 7098 if (context.allowFinalCommit()) { |
7099 // Need to fully commit as a single value. | 7099 // Need to fully commit as a single value. |
7100 result = context.commitBorderImageQuad(); | 7100 result = context.commitBorderImageQuad(); |
7101 return true; | 7101 return true; |
7102 } | 7102 } |
7103 return false; | 7103 return false; |
7104 } | 7104 } |
7105 | 7105 |
7106 bool CSSParser::parseBorderImageWidth(RefPtr<CSSPrimitiveValue>& result) | 7106 bool CSSParser::parseBorderImageWidth(RefPtr<CSSPrimitiveValue>& result) |
7107 { | 7107 { |
7108 return parseBorderImageQuad(FLength | FInteger | FNonNeg | FPercent, result)
; | 7108 return parseBorderImageQuad(FLength | FNumber | FNonNeg | FPercent, result); |
7109 } | 7109 } |
7110 | 7110 |
7111 bool CSSParser::parseBorderImageOutset(RefPtr<CSSPrimitiveValue>& result) | 7111 bool CSSParser::parseBorderImageOutset(RefPtr<CSSPrimitiveValue>& result) |
7112 { | 7112 { |
7113 return parseBorderImageQuad(FLength | FInteger | FNonNeg, result); | 7113 return parseBorderImageQuad(FLength | FNumber | FNonNeg, result); |
7114 } | 7114 } |
7115 | 7115 |
7116 static void completeBorderRadii(RefPtr<CSSPrimitiveValue> radii[4]) | 7116 static void completeBorderRadii(RefPtr<CSSPrimitiveValue> radii[4]) |
7117 { | 7117 { |
7118 if (radii[3]) | 7118 if (radii[3]) |
7119 return; | 7119 return; |
7120 if (!radii[2]) { | 7120 if (!radii[2]) { |
7121 if (!radii[1]) | 7121 if (!radii[1]) |
7122 radii[1] = radii[0]; | 7122 radii[1] = radii[0]; |
7123 radii[2] = radii[0]; | 7123 radii[2] = radii[0]; |
(...skipping 4829 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11953 { | 11953 { |
11954 // The tokenizer checks for the construct of an+b. | 11954 // The tokenizer checks for the construct of an+b. |
11955 // However, since the {ident} rule precedes the {nth} rule, some of those | 11955 // However, since the {ident} rule precedes the {nth} rule, some of those |
11956 // tokens are identified as string literal. Furthermore we need to accept | 11956 // tokens are identified as string literal. Furthermore we need to accept |
11957 // "odd" and "even" which does not match to an+b. | 11957 // "odd" and "even" which does not match to an+b. |
11958 return equalIgnoringCase(token, "odd") || equalIgnoringCase(token, "even") | 11958 return equalIgnoringCase(token, "odd") || equalIgnoringCase(token, "even") |
11959 || equalIgnoringCase(token, "n") || equalIgnoringCase(token, "-n"); | 11959 || equalIgnoringCase(token, "n") || equalIgnoringCase(token, "-n"); |
11960 } | 11960 } |
11961 | 11961 |
11962 } | 11962 } |
OLD | NEW |