From f2330fe08ed5e92b52c6c90d2230fe678e07eb17 Mon Sep 17 00:00:00 2001 From: "dimich@google.com" Date: Tue, 16 Jun 2009 00:37:09 +0000 Subject: Make XHR work in Workers. Creates a 'shadow page' in a worker process to proxy the loading requests through. BUG=4361 TEST=none Review URL: http://codereview.chromium.org/126070 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18465 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/renderer/renderer_glue.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'chrome/renderer/renderer_glue.cc') diff --git a/chrome/renderer/renderer_glue.cc b/chrome/renderer/renderer_glue.cc index be7893d..5f31444 100644 --- a/chrome/renderer/renderer_glue.cc +++ b/chrome/renderer/renderer_glue.cc @@ -225,7 +225,7 @@ ResourceLoaderBridge* ResourceLoaderBridge::Create( ResourceType::Type resource_type, int app_cache_context_id, int routing_id) { - ResourceDispatcher* dispatch = RenderThread::current()->resource_dispatcher(); + ResourceDispatcher* dispatch = ChildThread::current()->resource_dispatcher(); return dispatch->CreateBridge(method, url, first_party_for_cookies, referrer, frame_origin, main_frame_origin, headers, load_flags, origin_pid, resource_type, 0, @@ -236,7 +236,7 @@ void NotifyCacheStats() { // Update the browser about our cache // NOTE: Since this can be called from the plugin process, we might not have // a RenderThread. Do nothing in that case. - if (!IsPluginProcess()) + if (RenderThread::current()) RenderThread::current()->InformHostOfCacheStatsLater(); } -- cgit v1.1