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

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

Issue 113213002: Rename toWebCoreString*() utility methods to toCoreString*() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Keep "to" prefix Created 7 years 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
« no previous file with comments | « Source/bindings/v8/ScriptDebugServer.cpp ('k') | Source/bindings/v8/ScriptHeapSnapshot.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) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 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 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 v8::Context::Scope contextScope(context); 148 v8::Context::Scope contextScope(context);
149 v8::Handle<v8::Object> object = v8Listener->getListenerObject(document); 149 v8::Handle<v8::Object> object = v8Listener->getListenerObject(document);
150 if (object.IsEmpty() || !object->IsFunction()) 150 if (object.IsEmpty() || !object->IsFunction())
151 return false; 151 return false;
152 152
153 v8::Handle<v8::Function> function = v8::Handle<v8::Function>::Cast(object); 153 v8::Handle<v8::Function> function = v8::Handle<v8::Function>::Cast(object);
154 int scriptIdValue = function->ScriptId(); 154 int scriptIdValue = function->ScriptId();
155 scriptId = String::number(scriptIdValue); 155 scriptId = String::number(scriptIdValue);
156 v8::ScriptOrigin origin = function->GetScriptOrigin(); 156 v8::ScriptOrigin origin = function->GetScriptOrigin();
157 if (!origin.ResourceName().IsEmpty() && origin.ResourceName()->IsString()) 157 if (!origin.ResourceName().IsEmpty() && origin.ResourceName()->IsString())
158 sourceName = toWebCoreString(origin.ResourceName().As<v8::String>()); 158 sourceName = toCoreString(origin.ResourceName().As<v8::String>());
159 else 159 else
160 sourceName = ""; 160 sourceName = "";
161 lineNumber = function->GetScriptLineNumber(); 161 lineNumber = function->GetScriptLineNumber();
162 return true; 162 return true;
163 } 163 }
164 164
165 } // namespace WebCore 165 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/bindings/v8/ScriptDebugServer.cpp ('k') | Source/bindings/v8/ScriptHeapSnapshot.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698