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

Side by Side Diff: Source/core/css/RuleFeature.cpp

Issue 609813002: Use LocalStyleChange for content:attr() changes. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Added invalidation tests Created 6 years, 2 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com)
4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com)
5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All r ights reserved. 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All r ights reserved.
6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> 6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org>
7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> 7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org>
8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. 9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved.
10 * Copyright (C) Research In Motion Limited 2011. All rights reserved. 10 * Copyright (C) Research In Motion Limited 2011. All rights reserved.
(...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after
330 case CSSSelector::DirectAdjacent: 330 case CSSSelector::DirectAdjacent:
331 case CSSSelector::IndirectAdjacent: 331 case CSSSelector::IndirectAdjacent:
332 features.wholeSubtree = true; 332 features.wholeSubtree = true;
333 break; 333 break;
334 } 334 }
335 } 335 }
336 } 336 }
337 337
338 void RuleFeatureSet::addContentAttr(const AtomicString& attributeName) 338 void RuleFeatureSet::addContentAttr(const AtomicString& attributeName)
339 { 339 {
340 DescendantInvalidationSet& invalidationSet = ensureAttributeInvalidationSet( attributeName); 340 ensureAttributeInvalidationSet(attributeName);
341 invalidationSet.setWholeSubtreeInvalid();
342 } 341 }
343 342
344 void RuleFeatureSet::collectFeaturesFromRuleData(const RuleData& ruleData) 343 void RuleFeatureSet::collectFeaturesFromRuleData(const RuleData& ruleData)
345 { 344 {
346 FeatureMetadata metadata; 345 FeatureMetadata metadata;
347 InvalidationSetMode mode = updateInvalidationSets(ruleData.selector()); 346 InvalidationSetMode mode = updateInvalidationSets(ruleData.selector());
348 347
349 collectFeaturesFromSelector(ruleData.selector(), metadata, mode); 348 collectFeaturesFromSelector(ruleData.selector(), metadata, mode);
350 m_metadata.add(metadata); 349 m_metadata.add(metadata);
351 350
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
563 visitor->trace(uncommonAttributeRules); 562 visitor->trace(uncommonAttributeRules);
564 visitor->trace(m_classInvalidationSets); 563 visitor->trace(m_classInvalidationSets);
565 visitor->trace(m_attributeInvalidationSets); 564 visitor->trace(m_attributeInvalidationSets);
566 visitor->trace(m_idInvalidationSets); 565 visitor->trace(m_idInvalidationSets);
567 visitor->trace(m_pseudoInvalidationSets); 566 visitor->trace(m_pseudoInvalidationSets);
568 visitor->trace(m_styleInvalidator); 567 visitor->trace(m_styleInvalidator);
569 #endif 568 #endif
570 } 569 }
571 570
572 } // namespace blink 571 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698