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

Side by Side Diff: Source/bindings/tests/results/core/V8TestInterfaceNamedConstructor.cpp

Issue 820183002: [bindings] Make v8_class[Constructor]::domTemplate use Local<> instead of Handle<>. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@new-branch
Patch Set: Created 5 years, 12 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY! 5 // This file has been auto-generated by code_generator_v8.py. DO NOT MODIFY!
6 6
7 #include "config.h" 7 #include "config.h"
8 #include "V8TestInterfaceNamedConstructor.h" 8 #include "V8TestInterfaceNamedConstructor.h"
9 9
10 #include "bindings/core/v8/ExceptionState.h" 10 #include "bindings/core/v8/ExceptionState.h"
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 RefPtr<TestInterfaceNamedConstructor> impl = TestInterfaceNamedConstructor:: createForJSConstructor(document, stringArg, defaultUndefinedOptionalBooleanArg, defaultUndefinedOptionalLongArg, defaultUndefinedOptionalStringArg, defaultNullS tringOptionalstringArg, optionalStringArg, exceptionState); 110 RefPtr<TestInterfaceNamedConstructor> impl = TestInterfaceNamedConstructor:: createForJSConstructor(document, stringArg, defaultUndefinedOptionalBooleanArg, defaultUndefinedOptionalLongArg, defaultUndefinedOptionalStringArg, defaultNullS tringOptionalstringArg, optionalStringArg, exceptionState);
111 if (exceptionState.hadException()) { 111 if (exceptionState.hadException()) {
112 exceptionState.throwIfNeeded(); 112 exceptionState.throwIfNeeded();
113 return; 113 return;
114 } 114 }
115 v8::Local<v8::Object> wrapper = info.Holder(); 115 v8::Local<v8::Object> wrapper = info.Holder();
116 impl->associateWithWrapper(info.GetIsolate(), &V8TestInterfaceNamedConstruct orConstructor::wrapperTypeInfo, wrapper); 116 impl->associateWithWrapper(info.GetIsolate(), &V8TestInterfaceNamedConstruct orConstructor::wrapperTypeInfo, wrapper);
117 v8SetReturnValue(info, wrapper); 117 v8SetReturnValue(info, wrapper);
118 } 118 }
119 119
120 v8::Handle<v8::FunctionTemplate> V8TestInterfaceNamedConstructorConstructor::dom Template(v8::Isolate* isolate) 120 v8::Local<v8::FunctionTemplate> V8TestInterfaceNamedConstructorConstructor::domT emplate(v8::Isolate* isolate)
121 { 121 {
122 static int domTemplateKey; // This address is used for a key to look up the dom template. 122 static int domTemplateKey; // This address is used for a key to look up the dom template.
123 V8PerIsolateData* data = V8PerIsolateData::from(isolate); 123 V8PerIsolateData* data = V8PerIsolateData::from(isolate);
124 v8::Local<v8::FunctionTemplate> result = data->existingDOMTemplate(&domTempl ateKey); 124 v8::Local<v8::FunctionTemplate> result = data->existingDOMTemplate(&domTempl ateKey);
125 if (!result.IsEmpty()) 125 if (!result.IsEmpty())
126 return result; 126 return result;
127 127
128 TRACE_EVENT_SCOPED_SAMPLING_STATE("blink", "BuildDOMTemplate"); 128 TRACE_EVENT_SCOPED_SAMPLING_STATE("blink", "BuildDOMTemplate");
129 result = v8::FunctionTemplate::New(isolate, V8TestInterfaceNamedConstructorC onstructorCallback); 129 result = v8::FunctionTemplate::New(isolate, V8TestInterfaceNamedConstructorC onstructorCallback);
130 v8::Local<v8::ObjectTemplate> instanceTemplate = result->InstanceTemplate(); 130 v8::Local<v8::ObjectTemplate> instanceTemplate = result->InstanceTemplate();
(...skipping 15 matching lines...) Expand all
146 0, 0); 146 0, 0);
147 v8::Local<v8::ObjectTemplate> instanceTemplate = functionTemplate->InstanceT emplate(); 147 v8::Local<v8::ObjectTemplate> instanceTemplate = functionTemplate->InstanceT emplate();
148 ALLOW_UNUSED_LOCAL(instanceTemplate); 148 ALLOW_UNUSED_LOCAL(instanceTemplate);
149 v8::Local<v8::ObjectTemplate> prototypeTemplate = functionTemplate->Prototyp eTemplate(); 149 v8::Local<v8::ObjectTemplate> prototypeTemplate = functionTemplate->Prototyp eTemplate();
150 ALLOW_UNUSED_LOCAL(prototypeTemplate); 150 ALLOW_UNUSED_LOCAL(prototypeTemplate);
151 151
152 // Custom toString template 152 // Custom toString template
153 functionTemplate->Set(v8AtomicString(isolate, "toString"), V8PerIsolateData: :from(isolate)->toStringTemplate()); 153 functionTemplate->Set(v8AtomicString(isolate, "toString"), V8PerIsolateData: :from(isolate)->toStringTemplate());
154 } 154 }
155 155
156 v8::Handle<v8::FunctionTemplate> V8TestInterfaceNamedConstructor::domTemplate(v8 ::Isolate* isolate) 156 v8::Local<v8::FunctionTemplate> V8TestInterfaceNamedConstructor::domTemplate(v8: :Isolate* isolate)
157 { 157 {
158 return V8DOMConfiguration::domClassTemplate(isolate, const_cast<WrapperTypeI nfo*>(&wrapperTypeInfo), installV8TestInterfaceNamedConstructorTemplate); 158 return V8DOMConfiguration::domClassTemplate(isolate, const_cast<WrapperTypeI nfo*>(&wrapperTypeInfo), installV8TestInterfaceNamedConstructorTemplate);
159 } 159 }
160 160
161 bool V8TestInterfaceNamedConstructor::hasInstance(v8::Handle<v8::Value> v8Value, v8::Isolate* isolate) 161 bool V8TestInterfaceNamedConstructor::hasInstance(v8::Handle<v8::Value> v8Value, v8::Isolate* isolate)
162 { 162 {
163 return V8PerIsolateData::from(isolate)->hasInstance(&wrapperTypeInfo, v8Valu e); 163 return V8PerIsolateData::from(isolate)->hasInstance(&wrapperTypeInfo, v8Valu e);
164 } 164 }
165 165
166 v8::Handle<v8::Object> V8TestInterfaceNamedConstructor::findInstanceInPrototypeC hain(v8::Handle<v8::Value> v8Value, v8::Isolate* isolate) 166 v8::Handle<v8::Object> V8TestInterfaceNamedConstructor::findInstanceInPrototypeC hain(v8::Handle<v8::Value> v8Value, v8::Isolate* isolate)
(...skipping 15 matching lines...) Expand all
182 { 182 {
183 scriptWrappable->toImpl<TestInterfaceNamedConstructor>()->ref(); 183 scriptWrappable->toImpl<TestInterfaceNamedConstructor>()->ref();
184 } 184 }
185 185
186 void V8TestInterfaceNamedConstructor::derefObject(ScriptWrappable* scriptWrappab le) 186 void V8TestInterfaceNamedConstructor::derefObject(ScriptWrappable* scriptWrappab le)
187 { 187 {
188 scriptWrappable->toImpl<TestInterfaceNamedConstructor>()->deref(); 188 scriptWrappable->toImpl<TestInterfaceNamedConstructor>()->deref();
189 } 189 }
190 190
191 } // namespace blink 191 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698