Commit 8624fd2a authored by eric@webkit.org's avatar eric@webkit.org

2010-04-05 Andrey Kosyakov <caseq@chromium.org>

        Reviewed by Yury Semikhatsky.

        Remove logging of successful XHR and worker's importScript()
        to inspector console
        https://bugs.webkit.org/show_bug.cgi?id=37078

        * bindings/js/JSWorkerContextCustom.cpp:
        (WebCore::JSWorkerContext::importScripts):
        * bindings/v8/custom/V8WorkerContextCustom.cpp:
        (WebCore::V8WorkerContext::importScriptsCallback):
        * workers/DedicatedWorkerContext.cpp:
        (WebCore::DedicatedWorkerContext::importScripts):
        * workers/DedicatedWorkerContext.h:
        * workers/WorkerContext.cpp:
        (WebCore::WorkerContext::importScripts):
        * workers/WorkerContext.h:
        * xml/XMLHttpRequest.cpp:
        (WebCore::XMLHttpRequest::didFinishLoading):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@57068 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent b343bdc1
2010-04-05 Andrey Kosyakov <caseq@chromium.org>
Reviewed by Yury Semikhatsky.
Remove logging of successful XHR and worker's importScript()
to inspector console
https://bugs.webkit.org/show_bug.cgi?id=37078
* bindings/js/JSWorkerContextCustom.cpp:
(WebCore::JSWorkerContext::importScripts):
* bindings/v8/custom/V8WorkerContextCustom.cpp:
(WebCore::V8WorkerContext::importScriptsCallback):
* workers/DedicatedWorkerContext.cpp:
(WebCore::DedicatedWorkerContext::importScripts):
* workers/DedicatedWorkerContext.h:
* workers/WorkerContext.cpp:
(WebCore::WorkerContext::importScripts):
* workers/WorkerContext.h:
* xml/XMLHttpRequest.cpp:
(WebCore::XMLHttpRequest::didFinishLoading):
2010-04-04 Pavel Feldman <pfeldman@chromium.org>
Not reviewed. Rolling out chromium changes r57028 and r57032
......@@ -110,13 +110,8 @@ JSValue JSWorkerContext::importScripts(ExecState* exec, const ArgList& args)
return jsUndefined();
}
ExceptionCode ec = 0;
int signedLineNumber;
intptr_t sourceID;
UString sourceURL;
JSValue function;
exec->interpreter()->retrieveLastCaller(exec, signedLineNumber, sourceID, sourceURL, function);
impl()->importScripts(urls, sourceURL, signedLineNumber >= 0 ? signedLineNumber : 0, ec);
impl()->importScripts(urls, ec);
setDOMException(exec, ec);
return jsUndefined();
}
......
......@@ -90,14 +90,6 @@ v8::Handle<v8::Value> V8WorkerContext::importScriptsCallback(const v8::Arguments
if (!args.Length())
return v8::Undefined();
String callerURL;
if (!V8Proxy::sourceName(callerURL))
return v8::Undefined();
int callerLine;
if (!V8Proxy::sourceLineNumber(callerLine))
return v8::Undefined();
callerLine += 1;
Vector<String> urls;
for (int i = 0; i < args.Length(); i++) {
v8::TryCatch tryCatch;
......@@ -110,7 +102,7 @@ v8::Handle<v8::Value> V8WorkerContext::importScriptsCallback(const v8::Arguments
WorkerContext* workerContext = V8WorkerContext::toNative(args.Holder());
ExceptionCode ec = 0;
workerContext->importScripts(urls, callerURL, callerLine, ec);
workerContext->importScripts(urls, ec);
if (ec)
return throwError(ec);
......
......@@ -71,9 +71,9 @@ void DedicatedWorkerContext::postMessage(PassRefPtr<SerializedScriptValue> messa
thread()->workerObjectProxy().postMessageToWorkerObject(message, channels.release());
}
void DedicatedWorkerContext::importScripts(const Vector<String>& urls, const String& callerURL, int callerLine, ExceptionCode& ec)
void DedicatedWorkerContext::importScripts(const Vector<String>& urls, ExceptionCode& ec)
{
Base::importScripts(urls, callerURL, callerLine, ec);
Base::importScripts(urls, ec);
thread()->workerObjectProxy().reportPendingActivity(hasPendingActivity());
}
......
......@@ -51,7 +51,7 @@ namespace WebCore {
virtual bool isDedicatedWorkerContext() const { return true; }
// Overridden to allow us to check our pending activity after executing imported script.
virtual void importScripts(const Vector<String>& urls, const String& callerURL, int callerLine, ExceptionCode&);
virtual void importScripts(const Vector<String>& urls, ExceptionCode&);
// EventTarget
virtual DedicatedWorkerContext* toDedicatedWorkerContext() { return this; }
......
......@@ -188,12 +188,8 @@ void WorkerContext::clearInterval(int timeoutId)
DOMTimer::removeById(scriptExecutionContext(), timeoutId);
}
void WorkerContext::importScripts(const Vector<String>& urls, const String& callerURL, int callerLine, ExceptionCode& ec)
void WorkerContext::importScripts(const Vector<String>& urls, ExceptionCode& ec)
{
#if !ENABLE(INSPECTOR)
UNUSED_PARAM(callerURL);
UNUSED_PARAM(callerLine);
#endif
ec = 0;
Vector<String>::const_iterator urlsEnd = urls.end();
Vector<KURL> completedURLs;
......@@ -218,9 +214,6 @@ void WorkerContext::importScripts(const Vector<String>& urls, const String& call
}
scriptExecutionContext()->scriptImported(scriptLoader.identifier(), scriptLoader.script());
#if ENABLE(INSPECTOR)
scriptExecutionContext()->addMessage(InspectorControllerDestination, JSMessageSource, LogMessageType, LogMessageLevel, "Worker script imported: \"" + *it + "\".", callerLine, callerURL);
#endif
ScriptValue exception;
m_script->evaluate(ScriptSourceCode(scriptLoader.script(), *it), &exception);
......
......@@ -88,7 +88,7 @@ namespace WebCore {
DEFINE_ATTRIBUTE_EVENT_LISTENER(error);
// WorkerUtils
virtual void importScripts(const Vector<String>& urls, const String& callerURL, int callerLine, ExceptionCode&);
virtual void importScripts(const Vector<String>& urls, ExceptionCode&);
WorkerNavigator* navigator() const;
// Timers
......
......@@ -872,9 +872,6 @@ void XMLHttpRequest::didFinishLoading(unsigned long identifier)
m_responseText += m_decoder->flush();
scriptExecutionContext()->resourceRetrievedByXMLHttpRequest(identifier, m_responseText);
#if ENABLE(INSPECTOR)
scriptExecutionContext()->addMessage(InspectorControllerDestination, JSMessageSource, LogMessageType, LogMessageLevel, "XHR finished loading: \"" + m_url + "\".", m_lastSendLineNumber, m_lastSendURL);
#endif
bool hadLoader = m_loader;
m_loader = 0;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment