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

Side by Side Diff: Source/bindings/v8/V8WorkerGlobalScopeEventListener.cpp

Issue 234403004: Rename V8TRYCATCH_* macros in v8/V8BindingMacros.h (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: BOOL*_BOOL -> BOOL* Created 6 years, 8 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 | Annotate | Revision Log
« no previous file with comments | « Source/bindings/v8/V8Initializer.cpp ('k') | Source/bindings/v8/WorkerScriptController.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
85 if (handlerFunction.IsEmpty() || receiver.IsEmpty()) 85 if (handlerFunction.IsEmpty() || receiver.IsEmpty())
86 return v8::Local<v8::Value>(); 86 return v8::Local<v8::Value>();
87 87
88 InspectorInstrumentationCookie cookie; 88 InspectorInstrumentationCookie cookie;
89 if (InspectorInstrumentation::timelineAgentEnabled(context)) { 89 if (InspectorInstrumentation::timelineAgentEnabled(context)) {
90 String resourceName("undefined"); 90 String resourceName("undefined");
91 int lineNumber = 1; 91 int lineNumber = 1;
92 v8::Handle<v8::Function> originalFunction = getBoundFunction(handlerFunc tion); 92 v8::Handle<v8::Function> originalFunction = getBoundFunction(handlerFunc tion);
93 v8::ScriptOrigin origin = originalFunction->GetScriptOrigin(); 93 v8::ScriptOrigin origin = originalFunction->GetScriptOrigin();
94 if (!origin.ResourceName().IsEmpty()) { 94 if (!origin.ResourceName().IsEmpty()) {
95 V8TRYCATCH_FOR_V8STRINGRESOURCE_RETURN(V8StringResource<>, stringRes ourceName, origin.ResourceName(), v8::Local<v8::Value>()); 95 TOSTRING_BOOL(V8StringResource<>, stringResourceName, origin.Resourc eName(), v8::Local<v8::Value>());
96 resourceName = stringResourceName; 96 resourceName = stringResourceName;
97 lineNumber = originalFunction->GetScriptLineNumber() + 1; 97 lineNumber = originalFunction->GetScriptLineNumber() + 1;
98 } 98 }
99 cookie = InspectorInstrumentation::willCallFunction(context, originalFun ction->ScriptId(), resourceName, lineNumber); 99 cookie = InspectorInstrumentation::willCallFunction(context, originalFun ction->ScriptId(), resourceName, lineNumber);
100 } 100 }
101 101
102 v8::Isolate* isolate = toIsolate(context); 102 v8::Isolate* isolate = toIsolate(context);
103 v8::Handle<v8::Value> parameters[1] = { jsEvent }; 103 v8::Handle<v8::Value> parameters[1] = { jsEvent };
104 v8::Local<v8::Value> result = V8ScriptRunner::callFunction(handlerFunction, context, receiver, WTF_ARRAY_LENGTH(parameters), parameters, isolate); 104 v8::Local<v8::Value> result = V8ScriptRunner::callFunction(handlerFunction, context, receiver, WTF_ARRAY_LENGTH(parameters), parameters, isolate);
105 105
(...skipping 11 matching lines...) Expand all
117 117
118 EventTarget* target = event->currentTarget(); 118 EventTarget* target = event->currentTarget();
119 v8::Isolate* isolate = toIsolate(context); 119 v8::Isolate* isolate = toIsolate(context);
120 v8::Handle<v8::Value> value = toV8(target, v8::Handle<v8::Object>(), isolate ); 120 v8::Handle<v8::Value> value = toV8(target, v8::Handle<v8::Object>(), isolate );
121 if (value.IsEmpty()) 121 if (value.IsEmpty())
122 return v8::Local<v8::Object>(); 122 return v8::Local<v8::Object>();
123 return v8::Local<v8::Object>::New(isolate, v8::Handle<v8::Object>::Cast(valu e)); 123 return v8::Local<v8::Object>::New(isolate, v8::Handle<v8::Object>::Cast(valu e));
124 } 124 }
125 125
126 } // namespace WebCore 126 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/bindings/v8/V8Initializer.cpp ('k') | Source/bindings/v8/WorkerScriptController.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698