Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1281)

Unified Diff: content/renderer/renderer_webkitplatformsupport_impl.cc

Issue 8747002: Dispatch IndexedDB IPC messages to worker threads (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: inject thread ids into ipcs Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/renderer/renderer_webkitplatformsupport_impl.cc
diff --git a/content/renderer/renderer_webkitplatformsupport_impl.cc b/content/renderer/renderer_webkitplatformsupport_impl.cc
index e571411555def940f310a1936024f6893408741b..0bbb55c3935636c3f677245a59eea84de5993e5f 100644
--- a/content/renderer/renderer_webkitplatformsupport_impl.cc
+++ b/content/renderer/renderer_webkitplatformsupport_impl.cc
@@ -10,6 +10,7 @@
#include "base/platform_file.h"
#include "base/shared_memory.h"
#include "base/utf_string_conversions.h"
+#include "content/common/child_process.h"
#include "content/common/database_util.h"
#include "content/common/file_system/webfilesystem_impl.h"
#include "content/common/file_utilities_messages.h"
@@ -18,6 +19,7 @@
#include "content/common/view_messages.h"
#include "content/common/webblobregistry_impl.h"
#include "content/common/webmessageportchannel_impl.h"
+#include "content/common/worker_task_runner.h"
#include "content/public/common/content_switches.h"
#include "content/public/renderer/content_renderer_client.h"
#include "content/renderer/gpu/webgraphicscontext3d_command_buffer_impl.h"
@@ -631,3 +633,19 @@ void RendererWebKitPlatformSupportImpl::GetPlugins(
RenderThreadImpl::current()->Send(
new ViewHostMsg_GetPlugins(refresh, plugins));
}
+
+void RendererWebKitPlatformSupportImpl::didStartWorkerRunLoop(
+ const WebKit::WebWorkerRunLoop& runLoop) {
+ DCHECK(ChildThread::current());
+ WorkerTaskRunner* worker_tracker =
+ ChildThread::current()->worker_task_runner();
+ worker_tracker->RegisterCurrentWorkerLoop(runLoop);
+}
+
+void RendererWebKitPlatformSupportImpl::didStopWorkerRunLoop(
+ const WebKit::WebWorkerRunLoop& runLoop) {
+ DCHECK(ChildThread::current());
+ WorkerTaskRunner* worker_tracker =
+ ChildThread::current()->worker_task_runner();
+ worker_tracker->UnRegisterCurrentWorkerLoop(runLoop);
+}

Powered by Google App Engine
This is Rietveld 408576698