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

Unified Diff: third_party/WebKit/Source/bindings/core/v8/ScriptFunction.h

Issue 2173843002: binding: Removes createClosure(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/bindings/core/v8/ScriptFunction.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/bindings/core/v8/ScriptFunction.h
diff --git a/third_party/WebKit/Source/bindings/core/v8/ScriptFunction.h b/third_party/WebKit/Source/bindings/core/v8/ScriptFunction.h
index 21592756b5cc08b377a9ee70f2d71cd81ee775d5..2c306319bf78ff593ba3ba2e6b0a10b73a4576e6 100644
--- a/third_party/WebKit/Source/bindings/core/v8/ScriptFunction.h
+++ b/third_party/WebKit/Source/bindings/core/v8/ScriptFunction.h
@@ -53,15 +53,19 @@ namespace blink {
class CORE_EXPORT ScriptFunction : public GarbageCollectedFinalized<ScriptFunction> {
public:
virtual ~ScriptFunction() { }
- ScriptState* getScriptState() const { return m_scriptState.get(); }
DEFINE_INLINE_VIRTUAL_TRACE() { }
protected:
explicit ScriptFunction(ScriptState* scriptState)
: m_scriptState(scriptState)
+#if ENABLE(ASSERT)
+ , m_bindToV8FunctionAlreadyCalled(false)
+#endif
{
}
+ ScriptState* getScriptState() const { return m_scriptState.get(); }
+
v8::Local<v8::Function> bindToV8Function();
private:
@@ -69,6 +73,10 @@ private:
static void callCallback(const v8::FunctionCallbackInfo<v8::Value>&);
RefPtr<ScriptState> m_scriptState;
+#if ENABLE(ASSERT)
+ // bindToV8Function must not be called twice.
+ bool m_bindToV8FunctionAlreadyCalled;
+#endif
};
} // namespace blink
« no previous file with comments | « no previous file | third_party/WebKit/Source/bindings/core/v8/ScriptFunction.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698