OLD | NEW |
1 {% from "macros.tmpl" import license %} | 1 {% from "macros.tmpl" import license %} |
2 {{ license() }} | 2 {{ license() }} |
3 | 3 |
4 #include "config.h" | 4 #include "config.h" |
5 #include "{{namespace}}ElementFactory.h" | 5 #include "{{namespace}}ElementFactory.h" |
6 | 6 |
7 #include "{{namespace}}Names.h" | 7 #include "{{namespace}}Names.h" |
8 {% for tag in tags|sort %} | 8 {% for tag in tags|groupby('interface') %} |
9 #include "core/{{namespace|lower}}/{{tag.interface}}.h" | 9 #include "core/{{namespace|lower}}/{{tag[0]}}.h" |
10 {% endfor %} | 10 {% endfor %} |
11 {% if fallback_interface %} | 11 {% if fallback_interface %} |
12 #include "core/{{namespace|lower}}/{{fallback_interface}}.h" | 12 #include "core/{{namespace|lower}}/{{fallback_interface}}.h" |
13 {% endif %} | 13 {% endif %} |
14 #include "core/dom/custom/CustomElement.h" | 14 #include "core/dom/custom/CustomElement.h" |
15 #include "core/dom/custom/CustomElementRegistrationContext.h" | 15 #include "core/dom/custom/CustomElementRegistrationContext.h" |
16 #include "core/dom/Document.h" | 16 #include "core/dom/Document.h" |
17 #include "core/frame/Settings.h" | 17 #include "core/frame/Settings.h" |
18 #include "platform/RuntimeEnabledFeatures.h" | 18 #include "platform/RuntimeEnabledFeatures.h" |
19 #include "wtf/HashMap.h" | 19 #include "wtf/HashMap.h" |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 if (document.registrationContext() && CustomElement::isValidName(localName))
{ | 94 if (document.registrationContext() && CustomElement::isValidName(localName))
{ |
95 RefPtrWillBeRawPtr<Element> element = document.registrationContext()->cr
eateCustomTagElement(document, QualifiedName(nullAtom, localName, {{namespace_pr
efix}}NamespaceURI)); | 95 RefPtrWillBeRawPtr<Element> element = document.registrationContext()->cr
eateCustomTagElement(document, QualifiedName(nullAtom, localName, {{namespace_pr
efix}}NamespaceURI)); |
96 ASSERT_WITH_SECURITY_IMPLICATION(element->is{{namespace}}Element()); | 96 ASSERT_WITH_SECURITY_IMPLICATION(element->is{{namespace}}Element()); |
97 return static_pointer_cast<{{namespace}}Element>(element.release()); | 97 return static_pointer_cast<{{namespace}}Element>(element.release()); |
98 } | 98 } |
99 | 99 |
100 return {{fallback_interface}}::create(QualifiedName(nullAtom, localName, {{n
amespace_prefix}}NamespaceURI), document); | 100 return {{fallback_interface}}::create(QualifiedName(nullAtom, localName, {{n
amespace_prefix}}NamespaceURI), document); |
101 } | 101 } |
102 | 102 |
103 } // namespace blink | 103 } // namespace blink |
OLD | NEW |