diff options
author | kinuko@chromium.org <kinuko@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-27 19:34:40 +0000 |
---|---|---|
committer | kinuko@chromium.org <kinuko@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-27 19:34:40 +0000 |
commit | 503fa033dd50d1a0eac23a2da6ea6966ada4a2f6 (patch) | |
tree | 16c8af6fc4e676c1ab9784a8c3a795922702d48a /content/renderer/websharedworkerrepository_impl.cc | |
parent | c78ecec21cc998d5d41eeb292aba8333760a0e26 (diff) | |
download | chromium_src-503fa033dd50d1a0eac23a2da6ea6966ada4a2f6.zip chromium_src-503fa033dd50d1a0eac23a2da6ea6966ada4a2f6.tar.gz chromium_src-503fa033dd50d1a0eac23a2da6ea6966ada4a2f6.tar.bz2 |
Simplify SharedWorkerRepository code (Chromium side)
- Move scattered worker repository code into one class
(content::SharedWorkerRepository)
- Use per-page client which implements RenderViewObserver
- Implement RuntimeFeatures for shared workers
- No more WebKit:: static method to initialize repository
- Remove dead/unused code
Blink side patch (landed): https://codereview.chromium.org/40143003/
BUG=none
Review URL: https://codereview.chromium.org/40303002
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@231268 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/renderer/websharedworkerrepository_impl.cc')
-rw-r--r-- | content/renderer/websharedworkerrepository_impl.cc | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/content/renderer/websharedworkerrepository_impl.cc b/content/renderer/websharedworkerrepository_impl.cc deleted file mode 100644 index d914cf7..0000000 --- a/content/renderer/websharedworkerrepository_impl.cc +++ /dev/null @@ -1,35 +0,0 @@ -// Copyright 2009 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "content/renderer/websharedworkerrepository_impl.h" - -#include "content/child/child_thread.h" -#include "content/common/view_messages.h" -#include "content/renderer/websharedworker_proxy.h" - -namespace content { - -WebSharedWorkerRepositoryImpl::WebSharedWorkerRepositoryImpl() {} - -WebSharedWorkerRepositoryImpl::~WebSharedWorkerRepositoryImpl() {} - -void WebSharedWorkerRepositoryImpl::addSharedWorker( - WebKit::WebSharedWorker* worker, DocumentID document) { - shared_worker_parents_.insert(document); -} - -void WebSharedWorkerRepositoryImpl::documentDetached(DocumentID document) { - DocumentSet::iterator iter = shared_worker_parents_.find(document); - if (iter != shared_worker_parents_.end()) { - // Notify the browser process that the document has shut down. - ChildThread::current()->Send(new ViewHostMsg_DocumentDetached(document)); - shared_worker_parents_.erase(iter); - } -} - -bool WebSharedWorkerRepositoryImpl::hasSharedWorkers(DocumentID document) { - return shared_worker_parents_.find(document) != shared_worker_parents_.end(); -} - -} // namespace content |