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

Side by Side Diff: third_party/WebKit/Source/bindings/core/v8/V8CustomElementPerContextData.cpp

Issue 2003033004: Split custom element script use and move it into bindings (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add missing CORE_EXPORT header. Created 4 years, 6 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
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "bindings/core/v8/V8CustomElementPerContextData.h"
6
7 #include "bindings/core/v8/ScriptCustomElementDefinition.h"
8 #include "bindings/core/v8/V0CustomElementBinding.h"
9
10 namespace blink {
11
12 V8CustomElementPerContextData::V8CustomElementPerContextData()
13 {
14 }
15
16 V8CustomElementPerContextData::~V8CustomElementPerContextData()
17 {
18 }
19
20 DEFINE_TRACE(V8CustomElementPerContextData)
21 {
22 visitor->trace(m_definitions);
23 }
24
25 void V8CustomElementPerContextData::v0AddBinding(
26 PassOwnPtr<V0CustomElementBinding> binding)
27 {
28 m_v0Bindings.append(std::move(binding));
29 }
30
31 uint32_t V8CustomElementPerContextData::addDefinition(
32 ScriptCustomElementDefinition* def)
33 {
34 m_definitions.append(def);
35 return m_definitions.size() - 1;
36 }
37
38 ScriptCustomElementDefinition* V8CustomElementPerContextData::getDefinition(
39 uint32_t index)
40 {
41 return m_definitions[index];
42 }
43
44 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698