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 11226 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11237 endRuleBody(true); | 11237 endRuleBody(true); |
11238 return 0; | 11238 return 0; |
11239 } | 11239 } |
11240 } | 11240 } |
11241 RefPtr<StyleRuleFontFace> rule = StyleRuleFontFace::create(); | 11241 RefPtr<StyleRuleFontFace> rule = StyleRuleFontFace::create(); |
11242 rule->setProperties(createStylePropertySet()); | 11242 rule->setProperties(createStylePropertySet()); |
11243 clearProperties(); | 11243 clearProperties(); |
11244 StyleRuleFontFace* result = rule.get(); | 11244 StyleRuleFontFace* result = rule.get(); |
11245 m_parsedRules.append(rule.release()); | 11245 m_parsedRules.append(rule.release()); |
11246 endRuleBody(); | 11246 endRuleBody(); |
| 11247 if (m_styleSheet) |
| 11248 m_styleSheet->setHasFontFaceRule(true); |
11247 return result; | 11249 return result; |
11248 } | 11250 } |
11249 | 11251 |
11250 StyleRuleBase* CSSParser::createHostRule(RuleList* rules) | 11252 StyleRuleBase* CSSParser::createHostRule(RuleList* rules) |
11251 { | 11253 { |
11252 m_allowImportRules = m_allowNamespaceDeclarations = false; | 11254 m_allowImportRules = m_allowNamespaceDeclarations = false; |
11253 RefPtr<StyleRuleHost> rule; | 11255 RefPtr<StyleRuleHost> rule; |
11254 if (rules) | 11256 if (rules) |
11255 rule = StyleRuleHost::create(*rules); | 11257 rule = StyleRuleHost::create(*rules); |
11256 else { | 11258 else { |
(...skipping 661 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
11918 { | 11920 { |
11919 // The tokenizer checks for the construct of an+b. | 11921 // The tokenizer checks for the construct of an+b. |
11920 // However, since the {ident} rule precedes the {nth} rule, some of those | 11922 // However, since the {ident} rule precedes the {nth} rule, some of those |
11921 // tokens are identified as string literal. Furthermore we need to accept | 11923 // tokens are identified as string literal. Furthermore we need to accept |
11922 // "odd" and "even" which does not match to an+b. | 11924 // "odd" and "even" which does not match to an+b. |
11923 return equalIgnoringCase(token, "odd") || equalIgnoringCase(token, "even") | 11925 return equalIgnoringCase(token, "odd") || equalIgnoringCase(token, "even") |
11924 || equalIgnoringCase(token, "n") || equalIgnoringCase(token, "-n"); | 11926 || equalIgnoringCase(token, "n") || equalIgnoringCase(token, "-n"); |
11925 } | 11927 } |
11926 | 11928 |
11927 } | 11929 } |
OLD | NEW |