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

Side by Side Diff: Source/core/dom/custom/CustomElementRegistrationContext.h

Issue 296703009: Oilpan: move custom element objects to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 #include "wtf/text/AtomicString.h" 42 #include "wtf/text/AtomicString.h"
43 43
44 namespace WebCore { 44 namespace WebCore {
45 45
46 class CustomElementConstructorBuilder; 46 class CustomElementConstructorBuilder;
47 class CustomElementDefinition; 47 class CustomElementDefinition;
48 class Document; 48 class Document;
49 class Element; 49 class Element;
50 class ExceptionState; 50 class ExceptionState;
51 51
52 class CustomElementRegistrationContext : public RefCounted<CustomElementRegistra tionContext> { 52 class CustomElementRegistrationContext FINAL : public RefCountedWillBeGarbageCol lectedFinalized<CustomElementRegistrationContext> {
53 public: 53 public:
54 static PassRefPtr<CustomElementRegistrationContext> create(); 54 static PassRefPtrWillBeRawPtr<CustomElementRegistrationContext> create();
55 55
56 ~CustomElementRegistrationContext() { } 56 ~CustomElementRegistrationContext() { }
57 57
58 // Definitions 58 // Definitions
59 void registerElement(Document*, CustomElementConstructorBuilder*, const Atom icString& type, CustomElement::NameSet validNames, ExceptionState&); 59 void registerElement(Document*, CustomElementConstructorBuilder*, const Atom icString& type, CustomElement::NameSet validNames, ExceptionState&);
60 60
61 PassRefPtrWillBeRawPtr<Element> createCustomTagElement(Document&, const Qual ifiedName&); 61 PassRefPtrWillBeRawPtr<Element> createCustomTagElement(Document&, const Qual ifiedName&);
62 static void setIsAttributeAndTypeExtension(Element*, const AtomicString& typ e); 62 static void setIsAttributeAndTypeExtension(Element*, const AtomicString& typ e);
63 static void setTypeExtension(Element*, const AtomicString& type); 63 static void setTypeExtension(Element*, const AtomicString& type);
64 64
65 void resolve(Element*, const CustomElementDescriptor&); 65 void resolve(Element*, const CustomElementDescriptor&);
66 66
67 void trace(Visitor*);
68
67 protected: 69 protected:
68 CustomElementRegistrationContext() { } 70 CustomElementRegistrationContext() { }
69 71
70 // Instance creation 72 // Instance creation
71 void didGiveTypeExtension(Element*, const AtomicString& type); 73 void didGiveTypeExtension(Element*, const AtomicString& type);
72 74
73 private: 75 private:
74 void resolveOrScheduleResolution(Element*, const AtomicString& typeExtension ); 76 void resolveOrScheduleResolution(Element*, const AtomicString& typeExtension );
75 77
76 CustomElementRegistry m_registry; 78 CustomElementRegistry m_registry;
77 79
78 // Element creation 80 // Element creation
79 CustomElementUpgradeCandidateMap m_candidates; 81 OwnPtrWillBeMember<CustomElementUpgradeCandidateMap> m_candidates;
80 }; 82 };
81 83
82 } 84 }
83 85
84 #endif // CustomElementRegistrationContext_h 86 #endif // CustomElementRegistrationContext_h
85 87
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698