| OLD | NEW |
| 1 /* | 1 /* |
| 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) | 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2002-2003 Dirk Mueller (mueller@kde.org) | 3 * (C) 2002-2003 Dirk Mueller (mueller@kde.org) |
| 4 * Copyright (C) 2002, 2005, 2006, 2008, 2012 Apple Inc. All rights reserved. | 4 * Copyright (C) 2002, 2005, 2006, 2008, 2012 Apple Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 | 85 |
| 86 ASSERT(!selectorTextCache().contains(this)); | 86 ASSERT(!selectorTextCache().contains(this)); |
| 87 String text = generateSelectorText(); | 87 String text = generateSelectorText(); |
| 88 selectorTextCache().set(this, text); | 88 selectorTextCache().set(this, text); |
| 89 setHasCachedSelectorText(true); | 89 setHasCachedSelectorText(true); |
| 90 return text; | 90 return text; |
| 91 } | 91 } |
| 92 | 92 |
| 93 void CSSStyleRule::setSelectorText(const String& selectorText) | 93 void CSSStyleRule::setSelectorText(const String& selectorText) |
| 94 { | 94 { |
| 95 CSSParserContext context(parserContext(), 0); | 95 CSSParserContext context(parserContext(), 0, 0); |
| 96 CSSSelectorList selectorList; | 96 CSSSelectorList selectorList; |
| 97 CSSParser::parseSelector(context, selectorText, selectorList); | 97 CSSParser::parseSelector(context, selectorText, selectorList); |
| 98 if (!selectorList.isValid()) | 98 if (!selectorList.isValid()) |
| 99 return; | 99 return; |
| 100 | 100 |
| 101 CSSStyleSheet::RuleMutationScope mutationScope(this); | 101 CSSStyleSheet::RuleMutationScope mutationScope(this); |
| 102 | 102 |
| 103 m_styleRule->wrapperAdoptSelectorList(selectorList); | 103 m_styleRule->wrapperAdoptSelectorList(selectorList); |
| 104 | 104 |
| 105 if (hasCachedSelectorText()) { | 105 if (hasCachedSelectorText()) { |
| (...skipping 24 matching lines...) Expand all Loading... |
| 130 } | 130 } |
| 131 | 131 |
| 132 DEFINE_TRACE(CSSStyleRule) | 132 DEFINE_TRACE(CSSStyleRule) |
| 133 { | 133 { |
| 134 visitor->trace(m_styleRule); | 134 visitor->trace(m_styleRule); |
| 135 visitor->trace(m_propertiesCSSOMWrapper); | 135 visitor->trace(m_propertiesCSSOMWrapper); |
| 136 CSSRule::trace(visitor); | 136 CSSRule::trace(visitor); |
| 137 } | 137 } |
| 138 | 138 |
| 139 } // namespace blink | 139 } // namespace blink |
| OLD | NEW |