| 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 1500 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1511 | 1511 |
| 1512 static void recordSelectorStats(const CSSParserContext& context, const CSSSelect
orList& selectorList) | 1512 static void recordSelectorStats(const CSSParserContext& context, const CSSSelect
orList& selectorList) |
| 1513 { | 1513 { |
| 1514 if (!context.useCounter()) | 1514 if (!context.useCounter()) |
| 1515 return; | 1515 return; |
| 1516 | 1516 |
| 1517 for (const CSSSelector* selector = selectorList.first(); selector; selector
= CSSSelectorList::next(*selector)) { | 1517 for (const CSSSelector* selector = selectorList.first(); selector; selector
= CSSSelectorList::next(*selector)) { |
| 1518 for (const CSSSelector* current = selector; current ; current = current-
>tagHistory()) { | 1518 for (const CSSSelector* current = selector; current ; current = current-
>tagHistory()) { |
| 1519 UseCounter::Feature feature = UseCounter::NumberOfFeatures; | 1519 UseCounter::Feature feature = UseCounter::NumberOfFeatures; |
| 1520 switch (current->pseudoType()) { | 1520 switch (current->pseudoType()) { |
| 1521 case CSSSelector::PseudoUnresolved: | |
| 1522 feature = UseCounter::CSSSelectorPseudoUnresolved; | |
| 1523 break; | |
| 1524 case CSSSelector::PseudoHost: | 1521 case CSSSelector::PseudoHost: |
| 1525 feature = UseCounter::CSSSelectorPseudoHost; | 1522 feature = UseCounter::CSSSelectorPseudoHost; |
| 1526 break; | 1523 break; |
| 1527 default: | 1524 default: |
| 1528 break; | 1525 break; |
| 1529 } | 1526 } |
| 1530 if (feature != UseCounter::NumberOfFeatures) | 1527 if (feature != UseCounter::NumberOfFeatures) |
| 1531 context.useCounter()->count(feature); | 1528 context.useCounter()->count(feature); |
| 1532 if (current->selectorList()) | 1529 if (current->selectorList()) |
| 1533 recordSelectorStats(context, *current->selectorList()); | 1530 recordSelectorStats(context, *current->selectorList()); |
| (...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1700 m_observer->endProperty(isImportantFound, isPropertyParsed, m_tokenizer.
safeUserStringTokenOffset(), errorType); | 1697 m_observer->endProperty(isImportantFound, isPropertyParsed, m_tokenizer.
safeUserStringTokenOffset(), errorType); |
| 1701 } | 1698 } |
| 1702 | 1699 |
| 1703 void BisonCSSParser::startEndUnknownRule() | 1700 void BisonCSSParser::startEndUnknownRule() |
| 1704 { | 1701 { |
| 1705 if (m_observer) | 1702 if (m_observer) |
| 1706 m_observer->startEndUnknownRule(); | 1703 m_observer->startEndUnknownRule(); |
| 1707 } | 1704 } |
| 1708 | 1705 |
| 1709 } | 1706 } |
| OLD | NEW |