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

Side by Side Diff: Source/core/dom/Element.cpp

Issue 280123002: Oilpan: move LiveNodeList collections to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Have NodeRareData clear out NodeListsNodeData instead. Created 6 years, 7 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 | « Source/core/dom/Element.h ('k') | Source/core/dom/EmptyNodeList.h » ('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) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2001 Peter Kelly (pmk@post.com) 4 * (C) 2001 Peter Kelly (pmk@post.com)
5 * (C) 2001 Dirk Mueller (mueller@kde.org) 5 * (C) 2001 Dirk Mueller (mueller@kde.org)
6 * (C) 2007 David Smith (catfish.man@gmail.com) 6 * (C) 2007 David Smith (catfish.man@gmail.com)
7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc. All rights reserved. 7 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012, 2013 Apple Inc. All rights reserved.
8 * (C) 2007 Eric Seidel (eric@webkit.org) 8 * (C) 2007 Eric Seidel (eric@webkit.org)
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 2890 matching lines...) Expand 10 before | Expand all | Expand 10 after
2901 if (!document().isHTMLDocument()) 2901 if (!document().isHTMLDocument())
2902 return; 2902 return;
2903 2903
2904 if (!oldId.isEmpty()) 2904 if (!oldId.isEmpty())
2905 toHTMLDocument(document()).removeExtraNamedItem(oldId); 2905 toHTMLDocument(document()).removeExtraNamedItem(oldId);
2906 2906
2907 if (!newId.isEmpty()) 2907 if (!newId.isEmpty())
2908 toHTMLDocument(document()).addExtraNamedItem(newId); 2908 toHTMLDocument(document()).addExtraNamedItem(newId);
2909 } 2909 }
2910 2910
2911 PassRefPtr<HTMLCollection> Element::ensureCachedHTMLCollection(CollectionType ty pe) 2911 PassRefPtrWillBeRawPtr<HTMLCollection> Element::ensureCachedHTMLCollection(Colle ctionType type)
2912 { 2912 {
2913 if (HTMLCollection* collection = cachedHTMLCollection(type)) 2913 if (HTMLCollection* collection = cachedHTMLCollection(type))
2914 return collection; 2914 return collection;
2915 2915
2916 if (type == TableRows) { 2916 if (type == TableRows) {
2917 ASSERT(isHTMLTableElement(this)); 2917 ASSERT(isHTMLTableElement(this));
2918 return ensureRareData().ensureNodeLists().addCache<HTMLTableRowsCollecti on>(*this, type); 2918 return ensureRareData().ensureNodeLists().addCache<HTMLTableRowsCollecti on>(*this, type);
2919 } else if (type == SelectOptions) { 2919 } else if (type == SelectOptions) {
2920 ASSERT(isHTMLSelectElement(this)); 2920 ASSERT(isHTMLSelectElement(this));
2921 return ensureRareData().ensureNodeLists().addCache<HTMLOptionsCollection >(*this, type); 2921 return ensureRareData().ensureNodeLists().addCache<HTMLOptionsCollection >(*this, type);
(...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after
3301 3301
3302 void Element::trace(Visitor* visitor) 3302 void Element::trace(Visitor* visitor)
3303 { 3303 {
3304 if (hasRareData()) 3304 if (hasRareData())
3305 visitor->trace(elementRareData()); 3305 visitor->trace(elementRareData());
3306 3306
3307 ContainerNode::trace(visitor); 3307 ContainerNode::trace(visitor);
3308 } 3308 }
3309 3309
3310 } // namespace WebCore 3310 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/dom/Element.h ('k') | Source/core/dom/EmptyNodeList.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698