Chromium Code Reviews| Index: Source/core/dom/custom/CustomElementUpgradeCandidateMap.h |
| diff --git a/Source/core/dom/custom/CustomElementUpgradeCandidateMap.h b/Source/core/dom/custom/CustomElementUpgradeCandidateMap.h |
| index f68c50b65be76cea7412a881ba3ae7c256da5742..80e343be9b1f445c49ab3aad83a3c39c32e3bed5 100644 |
| --- a/Source/core/dom/custom/CustomElementUpgradeCandidateMap.h |
| +++ b/Source/core/dom/custom/CustomElementUpgradeCandidateMap.h |
| @@ -42,31 +42,35 @@ namespace WebCore { |
| class Element; |
| -class CustomElementUpgradeCandidateMap : CustomElementObserver { |
| +class CustomElementUpgradeCandidateMap FINAL : public CustomElementObserver { |
| WTF_MAKE_NONCOPYABLE(CustomElementUpgradeCandidateMap); |
| public: |
| - CustomElementUpgradeCandidateMap() { } |
| - ~CustomElementUpgradeCandidateMap(); |
| + static PassOwnPtrWillBeRawPtr<CustomElementUpgradeCandidateMap> create(); |
| + virtual ~CustomElementUpgradeCandidateMap(); |
| // API for CustomElementRegistrationContext to save and take candidates |
| - typedef ListHashSet<Element*> ElementSet; |
| + typedef WillBeHeapListHashSet<RawPtrWillBeMember<Element> > ElementSet; |
|
dominicc (has gone to gerrit)
2014/05/26 02:28:58
Hmm... the idea of the CustomElementUpgradeCandida
sof
2014/05/26 14:21:25
Thanks, the weakness of that reference must stay t
|
| void add(const CustomElementDescriptor&, Element*); |
| void remove(Element*); |
| ElementSet takeUpgradeCandidatesFor(const CustomElementDescriptor&); |
| + virtual void trace(Visitor*) OVERRIDE; |
| + |
| private: |
| + CustomElementUpgradeCandidateMap() { } |
| + |
| virtual void elementWasDestroyed(Element*) OVERRIDE; |
| void removeCommon(Element*); |
| virtual void elementDidFinishParsingChildren(Element*) OVERRIDE; |
| void moveToEnd(Element*); |
| - typedef HashMap<Element*, CustomElementDescriptor> UpgradeCandidateMap; |
| + typedef WillBeHeapHashMap<RawPtrWillBeMember<Element>, CustomElementDescriptor> UpgradeCandidateMap; |
| UpgradeCandidateMap m_upgradeCandidates; |
| - typedef HashMap<CustomElementDescriptor, ElementSet> UnresolvedDefinitionMap; |
| + typedef WillBeHeapHashMap<CustomElementDescriptor, ElementSet> UnresolvedDefinitionMap; |
| UnresolvedDefinitionMap m_unresolvedDefinitions; |
| }; |