Chromium Code Reviews| Index: third_party/WebKit/Source/bindings/core/v8/V8Binding.h |
| diff --git a/third_party/WebKit/Source/bindings/core/v8/V8Binding.h b/third_party/WebKit/Source/bindings/core/v8/V8Binding.h |
| index 81b839e5862974baf9cb0b5b6aac647a29e9b3a4..e35ea88bd7f72aea536e54f005095eeb35867a8d 100644 |
| --- a/third_party/WebKit/Source/bindings/core/v8/V8Binding.h |
| +++ b/third_party/WebKit/Source/bindings/core/v8/V8Binding.h |
| @@ -1004,6 +1004,11 @@ CORE_EXPORT v8::Local<v8::Context> toV8Context(LocalFrame*, DOMWrapperWorld&); |
| CORE_EXPORT v8::Local<v8::Context> toV8ContextEvenIfDetached(LocalFrame*, |
| DOMWrapperWorld&); |
| +// These methods can return nullptr if the context associated with the |
| +// ScriptState has already been detached. |
| +CORE_EXPORT ScriptState* toScriptState(LocalFrame*, DOMWrapperWorld&); |
| +CORE_EXPORT ScriptState* toScriptStateForMainWorld(LocalFrame*); |
|
haraken
2017/04/04 02:26:44
Nit: I'd add:
// Do not use this method unless
adithyas
2017/04/04 14:22:42
Done.
|
| + |
| // Returns the frame object of the window object associated with |
| // a context, if the window is currently being displayed in a Frame. |
| CORE_EXPORT LocalFrame* toLocalFrameIfNotDetached(v8::Local<v8::Context>); |