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

Unified Diff: Source/bindings/v8/custom/V8WorkerGlobalScopeCustom.cpp

Issue 171333003: Pass implementation object to supplemental classes by reference (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase Created 6 years, 10 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
Index: Source/bindings/v8/custom/V8WorkerGlobalScopeCustom.cpp
diff --git a/Source/bindings/v8/custom/V8WorkerGlobalScopeCustom.cpp b/Source/bindings/v8/custom/V8WorkerGlobalScopeCustom.cpp
index 1863af5992cc6ceb1bf7f69e468c6127a9d8d0a2..446b5a68546be62cee20754dbcb91d01fa5630c5 100644
--- a/Source/bindings/v8/custom/V8WorkerGlobalScopeCustom.cpp
+++ b/Source/bindings/v8/custom/V8WorkerGlobalScopeCustom.cpp
@@ -50,6 +50,7 @@ namespace WebCore {
void SetTimeoutOrInterval(const v8::FunctionCallbackInfo<v8::Value>& info, bool singleShot)
{
WorkerGlobalScope* workerGlobalScope = V8WorkerGlobalScope::toNative(info.Holder());
+ ASSERT(workerGlobalScope);
int argumentCount = info.Length();
if (argumentCount < 1)
@@ -87,9 +88,9 @@ void SetTimeoutOrInterval(const v8::FunctionCallbackInfo<v8::Value>& info, bool
int32_t timeout = argumentCount >= 2 ? info[1]->Int32Value() : 0;
int timerId;
if (singleShot)
- timerId = DOMWindowTimers::setTimeout(workerGlobalScope, action.release(), timeout);
+ timerId = DOMWindowTimers::setTimeout(*workerGlobalScope, action.release(), timeout);
else
- timerId = DOMWindowTimers::setInterval(workerGlobalScope, action.release(), timeout);
+ timerId = DOMWindowTimers::setInterval(*workerGlobalScope, action.release(), timeout);
v8SetReturnValue(info, timerId);
}

Powered by Google App Engine
This is Rietveld 408576698