Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(707)

Side by Side Diff: sky/engine/core/html/HTMLContentElement.cpp

Issue 867903002: Remove UseCounter (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « sky/engine/core/html/HTMLAnchorElement.cpp ('k') | sky/engine/core/html/HTMLImageElement.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Neither the name of Google Inc. nor the names of its 10 * * Neither the name of Google Inc. nor the names of its
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 DEFINE_NODE_FACTORY(HTMLContentElement) 47 DEFINE_NODE_FACTORY(HTMLContentElement)
48 48
49 HTMLContentElement::~HTMLContentElement() 49 HTMLContentElement::~HTMLContentElement()
50 { 50 {
51 } 51 }
52 52
53 void HTMLContentElement::parseSelect() 53 void HTMLContentElement::parseSelect()
54 { 54 {
55 ASSERT(m_shouldParseSelect); 55 ASSERT(m_shouldParseSelect);
56 56
57 BisonCSSParser parser(CSSParserContext(document(), 0)); 57 CSSParserContext context(document());
58 BisonCSSParser parser(context);
58 parser.parseSelector(m_select, m_selectorList); 59 parser.parseSelector(m_select, m_selectorList);
59 m_shouldParseSelect = false; 60 m_shouldParseSelect = false;
60 m_isValidSelector = validateSelect(); 61 m_isValidSelector = validateSelect();
61 if (!m_isValidSelector) { 62 if (!m_isValidSelector) {
62 CSSSelectorList emptyList; 63 CSSSelectorList emptyList;
63 m_selectorList.adopt(emptyList); 64 m_selectorList.adopt(emptyList);
64 } 65 }
65 } 66 }
66 67
67 void HTMLContentElement::parseAttribute(const QualifiedName& name, const AtomicS tring& value) 68 void HTMLContentElement::parseAttribute(const QualifiedName& name, const AtomicS tring& value)
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 { 112 {
112 for (const CSSSelector* selector = selectorList().first(); selector; selecto r = CSSSelectorList::next(*selector)) { 113 for (const CSSSelector* selector = selectorList().first(); selector; selecto r = CSSSelectorList::next(*selector)) {
113 SelectorChecker checker(toElement(*siblings[nth])); 114 SelectorChecker checker(toElement(*siblings[nth]));
114 if (checker.match(*selector)) 115 if (checker.match(*selector))
115 return true; 116 return true;
116 } 117 }
117 return false; 118 return false;
118 } 119 }
119 120
120 } 121 }
OLDNEW
« no previous file with comments | « sky/engine/core/html/HTMLAnchorElement.cpp ('k') | sky/engine/core/html/HTMLImageElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698