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

Side by Side Diff: Source/bindings/core/v8/V8BindingForTesting.cpp

Issue 1111163003: Replace v8::Handle<> with v8::Local<> in bindings/core/v8/* (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 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 // Copyright (c) 2015 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2015 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 #include "config.h" 5 #include "config.h"
6 #include "bindings/core/v8/V8BindingForTesting.h" 6 #include "bindings/core/v8/V8BindingForTesting.h"
7 7
8 #include "bindings/core/v8/DOMWrapperWorld.h" 8 #include "bindings/core/v8/DOMWrapperWorld.h"
9 9
10 namespace blink { 10 namespace blink {
11 11
12 PassRefPtr<ScriptStateForTesting> ScriptStateForTesting::create(v8::Handle<v8::C ontext> context, PassRefPtr<DOMWrapperWorld> world) 12 PassRefPtr<ScriptStateForTesting> ScriptStateForTesting::create(v8::Local<v8::Co ntext> context, PassRefPtr<DOMWrapperWorld> world)
13 { 13 {
14 RefPtr<ScriptStateForTesting> scriptState = adoptRef(new ScriptStateForTesti ng(context, world)); 14 RefPtr<ScriptStateForTesting> scriptState = adoptRef(new ScriptStateForTesti ng(context, world));
15 // This ref() is for keeping this ScriptState alive as long as the v8::Conte xt is alive. 15 // This ref() is for keeping this ScriptState alive as long as the v8::Conte xt is alive.
16 // This is deref()ed in the weak callback of the v8::Context. 16 // This is deref()ed in the weak callback of the v8::Context.
17 scriptState->ref(); 17 scriptState->ref();
18 return scriptState; 18 return scriptState;
19 } 19 }
20 20
21 ScriptStateForTesting::ScriptStateForTesting(v8::Handle<v8::Context> context, Pa ssRefPtr<DOMWrapperWorld> world) 21 ScriptStateForTesting::ScriptStateForTesting(v8::Local<v8::Context> context, Pas sRefPtr<DOMWrapperWorld> world)
22 : ScriptState(context, world) 22 : ScriptState(context, world)
23 { 23 {
24 } 24 }
25 25
26 ExecutionContext* ScriptStateForTesting::executionContext() const 26 ExecutionContext* ScriptStateForTesting::executionContext() const
27 { 27 {
28 return m_executionContext; 28 return m_executionContext;
29 } 29 }
30 30
31 void ScriptStateForTesting::setExecutionContext(ExecutionContext* executionConte xt) 31 void ScriptStateForTesting::setExecutionContext(ExecutionContext* executionConte xt)
(...skipping 23 matching lines...) Expand all
55 { 55 {
56 return m_scriptState->isolate(); 56 return m_scriptState->isolate();
57 } 57 }
58 58
59 v8::Local<v8::Context> V8TestingScope::context() const 59 v8::Local<v8::Context> V8TestingScope::context() const
60 { 60 {
61 return m_scriptState->context(); 61 return m_scriptState->context();
62 } 62 }
63 63
64 } // namespace blink 64 } // namespace blink
OLDNEW
« no previous file with comments | « Source/bindings/core/v8/V8BindingForTesting.h ('k') | Source/bindings/core/v8/V8Initializer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698