| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 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 237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 248 } | 248 } |
| 249 | 249 |
| 250 void WebEmbeddedWorkerImpl::detachDevTools() | 250 void WebEmbeddedWorkerImpl::detachDevTools() |
| 251 { | 251 { |
| 252 m_workerThread->runLoop().postDebuggerTask(createCallbackTask(disconnectFrom
WorkerContextInspectorTask, true)); | 252 m_workerThread->runLoop().postDebuggerTask(createCallbackTask(disconnectFrom
WorkerContextInspectorTask, true)); |
| 253 } | 253 } |
| 254 | 254 |
| 255 void WebEmbeddedWorkerImpl::dispatchDevToolsMessage(const WebString& message) | 255 void WebEmbeddedWorkerImpl::dispatchDevToolsMessage(const WebString& message) |
| 256 { | 256 { |
| 257 m_workerThread->runLoop().postDebuggerTask(createCallbackTask(dispatchOnInsp
ectorBackendTask, String(message))); | 257 m_workerThread->runLoop().postDebuggerTask(createCallbackTask(dispatchOnInsp
ectorBackendTask, String(message))); |
| 258 WorkerDebuggerAgent::interruptAndDispatchInspectorCommands(m_workerThread.ge
t()); | 258 m_workerThread->interruptAndDispatchInspectorCommands(); |
| 259 } | 259 } |
| 260 | 260 |
| 261 void WebEmbeddedWorkerImpl::prepareShadowPageForLoader() | 261 void WebEmbeddedWorkerImpl::prepareShadowPageForLoader() |
| 262 { | 262 { |
| 263 // Create 'shadow page', which is never displayed and is used mainly to | 263 // Create 'shadow page', which is never displayed and is used mainly to |
| 264 // provide a context for loading on the main thread. | 264 // provide a context for loading on the main thread. |
| 265 // | 265 // |
| 266 // FIXME: This does mostly same as WebSharedWorkerImpl::initializeLoader. | 266 // FIXME: This does mostly same as WebSharedWorkerImpl::initializeLoader. |
| 267 // This code, and probably most of the code in this class should be shared | 267 // This code, and probably most of the code in this class should be shared |
| 268 // with SharedWorker. | 268 // with SharedWorker. |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 354 m_mainScriptLoader.clear(); | 354 m_mainScriptLoader.clear(); |
| 355 | 355 |
| 356 m_workerGlobalScopeProxy = ServiceWorkerGlobalScopeProxy::create(*this, *toW
ebLocalFrameImpl(m_mainFrame)->frame()->document(), *m_workerContextClient); | 356 m_workerGlobalScopeProxy = ServiceWorkerGlobalScopeProxy::create(*this, *toW
ebLocalFrameImpl(m_mainFrame)->frame()->document(), *m_workerContextClient); |
| 357 m_loaderProxy = LoaderProxy::create(*this); | 357 m_loaderProxy = LoaderProxy::create(*this); |
| 358 | 358 |
| 359 m_workerThread = ServiceWorkerThread::create(*m_loaderProxy, *m_workerGlobal
ScopeProxy, startupData.release()); | 359 m_workerThread = ServiceWorkerThread::create(*m_loaderProxy, *m_workerGlobal
ScopeProxy, startupData.release()); |
| 360 m_workerThread->start(); | 360 m_workerThread->start(); |
| 361 } | 361 } |
| 362 | 362 |
| 363 } // namespace blink | 363 } // namespace blink |
| OLD | NEW |