summaryrefslogtreecommitdiffstats
path: root/WebCore/workers/WorkerContext.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/workers/WorkerContext.cpp')
-rw-r--r--WebCore/workers/WorkerContext.cpp30
1 files changed, 2 insertions, 28 deletions
diff --git a/WebCore/workers/WorkerContext.cpp b/WebCore/workers/WorkerContext.cpp
index 3cb1733..722588f 100644
--- a/WebCore/workers/WorkerContext.cpp
+++ b/WebCore/workers/WorkerContext.cpp
@@ -50,10 +50,6 @@
#include "XMLHttpRequestException.h"
#include <wtf/RefPtr.h>
-#if ENABLE(NOTIFICATIONS)
-#include "NotificationCenter.h"
-#endif
-
namespace WebCore {
WorkerContext::WorkerContext(const KURL& url, const String& userAgent, WorkerThread* thread)
@@ -68,12 +64,6 @@ WorkerContext::WorkerContext(const KURL& url, const String& userAgent, WorkerThr
WorkerContext::~WorkerContext()
{
- ASSERT(currentThread() == thread()->threadID());
-#if ENABLE(NOTIFICATIONS)
- m_notifications.clear();
-#endif
- // Notify proxy that we are going away. This can free the WorkerThread object, so do not access it after this.
- thread()->workerReportingProxy().workerContextDestroyed();
}
ScriptExecutionContext* WorkerContext::scriptExecutionContext() const
@@ -119,8 +109,6 @@ void WorkerContext::close()
return;
m_closing = true;
- // Notify parent that this context is closed.
- thread()->workerReportingProxy().workerContextClosed();
m_thread->stop();
}
@@ -256,7 +244,7 @@ void WorkerContext::importScripts(const Vector<String>& urls, const String& call
for (Vector<KURL>::const_iterator it = completedURLs.begin(); it != end; ++it) {
WorkerScriptLoader scriptLoader;
- scriptLoader.loadSynchronously(scriptExecutionContext(), *it, AllowCrossOriginRequests);
+ scriptLoader.loadSynchronously(scriptExecutionContext(), *it, AllowCrossOriginRedirect);
// If the fetching attempt failed, throw a NETWORK_ERR exception and abort all these steps.
if (scriptLoader.failed()) {
@@ -283,22 +271,8 @@ void WorkerContext::reportException(const String& errorMessage, int lineNumber,
errorHandled = onerror()->reportError(errorMessage, sourceURL, lineNumber);
if (!errorHandled)
- thread()->workerReportingProxy().postExceptionToWorkerObject(errorMessage, lineNumber, sourceURL);
-}
-
-void WorkerContext::addMessage(MessageDestination destination, MessageSource source, MessageType type, MessageLevel level, const String& message, unsigned lineNumber, const String& sourceURL)
-{
- thread()->workerReportingProxy().postConsoleMessageToWorkerObject(destination, source, type, level, message, lineNumber, sourceURL);
-}
-
-#if ENABLE(NOTIFICATIONS)
-NotificationCenter* WorkerContext::webkitNotifications() const
-{
- if (!m_notifications)
- m_notifications = NotificationCenter::create(scriptExecutionContext(), m_thread->getNotificationPresenter());
- return m_notifications.get();
+ forwardException(errorMessage, lineNumber, sourceURL);
}
-#endif
} // namespace WebCore