| 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 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 void ServiceWorkerGlobalScopeProxy::reportConsoleMessage(PassRefPtrWillBeRawPtr<
ConsoleMessage> consoleMessage) | 137 void ServiceWorkerGlobalScopeProxy::reportConsoleMessage(PassRefPtrWillBeRawPtr<
ConsoleMessage> consoleMessage) |
| 138 { | 138 { |
| 139 m_client.reportConsoleMessage(consoleMessage->source(), consoleMessage->leve
l(), consoleMessage->message(), consoleMessage->lineNumber(), consoleMessage->ur
l()); | 139 m_client.reportConsoleMessage(consoleMessage->source(), consoleMessage->leve
l(), consoleMessage->message(), consoleMessage->lineNumber(), consoleMessage->ur
l()); |
| 140 } | 140 } |
| 141 | 141 |
| 142 void ServiceWorkerGlobalScopeProxy::postMessageToPageInspector(const String& mes
sage) | 142 void ServiceWorkerGlobalScopeProxy::postMessageToPageInspector(const String& mes
sage) |
| 143 { | 143 { |
| 144 m_document.postInspectorTask(createCrossThreadTask(&WebEmbeddedWorkerImpl::p
ostMessageToPageInspector, &m_embeddedWorker, message)); | 144 m_document.postInspectorTask(createCrossThreadTask(&WebEmbeddedWorkerImpl::p
ostMessageToPageInspector, &m_embeddedWorker, message)); |
| 145 } | 145 } |
| 146 | 146 |
| 147 void ServiceWorkerGlobalScopeProxy::updateInspectorStateCookie(const String& mes
sage) | |
| 148 { | |
| 149 // The inspector cookie saving/restoring is controlled from the main thread. | |
| 150 // This method could be removed once shared workers are moved to the main th
read inspection as well. | |
| 151 } | |
| 152 | |
| 153 void ServiceWorkerGlobalScopeProxy::workerGlobalScopeStarted(WorkerGlobalScope*
workerGlobalScope) | 147 void ServiceWorkerGlobalScopeProxy::workerGlobalScopeStarted(WorkerGlobalScope*
workerGlobalScope) |
| 154 { | 148 { |
| 155 ASSERT(!m_workerGlobalScope); | 149 ASSERT(!m_workerGlobalScope); |
| 156 m_workerGlobalScope = workerGlobalScope; | 150 m_workerGlobalScope = workerGlobalScope; |
| 157 m_client.workerContextStarted(this); | 151 m_client.workerContextStarted(this); |
| 158 } | 152 } |
| 159 | 153 |
| 160 void ServiceWorkerGlobalScopeProxy::workerGlobalScopeClosed() | 154 void ServiceWorkerGlobalScopeProxy::workerGlobalScopeClosed() |
| 161 { | 155 { |
| 162 m_document.postTask(createCrossThreadTask(&WebEmbeddedWorkerImpl::terminateW
orkerContext, &m_embeddedWorker)); | 156 m_document.postTask(createCrossThreadTask(&WebEmbeddedWorkerImpl::terminateW
orkerContext, &m_embeddedWorker)); |
| (...skipping 12 matching lines...) Expand all Loading... |
| 175 | 169 |
| 176 ServiceWorkerGlobalScopeProxy::ServiceWorkerGlobalScopeProxy(WebEmbeddedWorkerIm
pl& embeddedWorker, Document& document, WebServiceWorkerContextClient& client) | 170 ServiceWorkerGlobalScopeProxy::ServiceWorkerGlobalScopeProxy(WebEmbeddedWorkerIm
pl& embeddedWorker, Document& document, WebServiceWorkerContextClient& client) |
| 177 : m_embeddedWorker(embeddedWorker) | 171 : m_embeddedWorker(embeddedWorker) |
| 178 , m_document(document) | 172 , m_document(document) |
| 179 , m_client(client) | 173 , m_client(client) |
| 180 , m_workerGlobalScope(0) | 174 , m_workerGlobalScope(0) |
| 181 { | 175 { |
| 182 } | 176 } |
| 183 | 177 |
| 184 } // namespace blink | 178 } // namespace blink |
| OLD | NEW |