diff options
author | piman@chromium.org <piman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-10 20:51:22 +0000 |
---|---|---|
committer | piman@chromium.org <piman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-10 20:51:22 +0000 |
commit | 5f33a97da833172380b8261a1861bc9b862e4b89 (patch) | |
tree | d2cd901009cf9196a79dce98a1e89deebea5a575 /content | |
parent | ad5ffd21e2429949a2e5bf341d876acdeee69ce9 (diff) | |
download | chromium_src-5f33a97da833172380b8261a1861bc9b862e4b89.zip chromium_src-5f33a97da833172380b8261a1861bc9b862e4b89.tar.gz chromium_src-5f33a97da833172380b8261a1861bc9b862e4b89.tar.bz2 |
Rename GpuProcessHost::GetForRenderer to GetForClient
BUG=none
TEST=compiles
Review URL: http://codereview.chromium.org/9370038
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@121519 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
-rw-r--r-- | content/browser/gpu/browser_gpu_channel_host_factory.cc | 2 | ||||
-rw-r--r-- | content/browser/gpu/gpu_process_host.cc | 5 | ||||
-rw-r--r-- | content/browser/gpu/gpu_process_host.h | 21 | ||||
-rw-r--r-- | content/browser/renderer_host/gpu_message_filter.cc | 2 |
4 files changed, 14 insertions, 16 deletions
diff --git a/content/browser/gpu/browser_gpu_channel_host_factory.cc b/content/browser/gpu/browser_gpu_channel_host_factory.cc index 1b7fb7d..06ef537 100644 --- a/content/browser/gpu/browser_gpu_channel_host_factory.cc +++ b/content/browser/gpu/browser_gpu_channel_host_factory.cc @@ -132,7 +132,7 @@ void BrowserGpuChannelHostFactory::EstablishGpuChannelOnIO( CauseForGpuLaunch cause_for_gpu_launch) { GpuProcessHost* host = GpuProcessHost::FromID(gpu_host_id_); if (!host) { - host = GpuProcessHost::GetForRenderer(gpu_client_id_, cause_for_gpu_launch); + host = GpuProcessHost::GetForClient(gpu_client_id_, cause_for_gpu_launch); if (!host) { request->event.Signal(); return; diff --git a/content/browser/gpu/gpu_process_host.cc b/content/browser/gpu/gpu_process_host.cc index cf2d7ef..bd0f553 100644 --- a/content/browser/gpu/gpu_process_host.cc +++ b/content/browser/gpu/gpu_process_host.cc @@ -80,8 +80,7 @@ void ReleasePermanentXIDDispatcher(gfx::PluginWindowHandle surface) { void SendGpuProcessMessage(int client_id, content::CauseForGpuLaunch cause, IPC::Message* message) { - GpuProcessHost* host = GpuProcessHost::GetForRenderer( - client_id, cause); + GpuProcessHost* host = GpuProcessHost::GetForClient(client_id, cause); if (host) { host->Send(message); } else { @@ -186,7 +185,7 @@ bool GpuProcessHost::HostIsValid(GpuProcessHost* host) { } // static -GpuProcessHost* GpuProcessHost::GetForRenderer( +GpuProcessHost* GpuProcessHost::GetForClient( int client_id, content::CauseForGpuLaunch cause) { DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); diff --git a/content/browser/gpu/gpu_process_host.h b/content/browser/gpu/gpu_process_host.h index c1394cb..30a7dcf 100644 --- a/content/browser/gpu/gpu_process_host.h +++ b/content/browser/gpu/gpu_process_host.h @@ -31,17 +31,16 @@ class GpuProcessHost : public content::BrowserChildProcessHostDelegate, public: static bool gpu_enabled() { return gpu_enabled_; } - // Creates a new GpuProcessHost or gets one for a particular - // renderer process, resulting in the launching of a GPU process if required. - // Returns null on failure. It is not safe to store the pointer once control - // has returned to the message loop as it can be destroyed. Instead store the - // associated GPU host ID. A renderer ID of zero means the browser process. + // Creates a new GpuProcessHost or gets one for a particular client, resulting + // in the launching of a GPU process if required. Returns null on failure. It + // is not safe to store the pointer once control has returned to the message + // loop as it can be destroyed. Instead store the associated GPU host ID. // This could return NULL if GPU access is not allowed (blacklisted). - static GpuProcessHost* GetForRenderer(int client_id, - content::CauseForGpuLaunch cause); + static GpuProcessHost* GetForClient(int client_id, + content::CauseForGpuLaunch cause); // Helper function to send the given message to the GPU process on the IO - // thread. Calls GetForRenderer and if a host is returned, sends it. + // thread. Calls GetForClient and if a host is returned, sends it. // Can be called from any thread. CONTENT_EXPORT static void SendOnIO(int client_id, content::CauseForGpuLaunch cause, @@ -61,7 +60,7 @@ class GpuProcessHost : public content::BrowserChildProcessHostDelegate, EstablishChannelCallback; // Tells the GPU process to create a new channel for communication with a - // renderer. Once the GPU process responds asynchronously with the IPC handle + // client. Once the GPU process responds asynchronously with the IPC handle // and GPUInfo, we call the callback. void EstablishGpuChannel( int client_id, const EstablishChannelCallback& callback); @@ -69,7 +68,7 @@ class GpuProcessHost : public content::BrowserChildProcessHostDelegate, typedef base::Callback<void(int32)> CreateCommandBufferCallback; // Tells the GPU process to create a new command buffer that draws into the - // window associated with the given renderer. + // given surface. void CreateViewCommandBuffer( gfx::GLSurfaceHandle compositing_surface, int surface_id, @@ -113,7 +112,7 @@ class GpuProcessHost : public content::BrowserChildProcessHostDelegate, void EstablishChannelError( const EstablishChannelCallback& callback, const IPC::ChannelHandle& channel_handle, - base::ProcessHandle renderer_process_for_gpu, + base::ProcessHandle client_process_for_gpu, const content::GPUInfo& gpu_info); void CreateCommandBufferError(const CreateCommandBufferCallback& callback, int32 route_id); diff --git a/content/browser/renderer_host/gpu_message_filter.cc b/content/browser/renderer_host/gpu_message_filter.cc index 0cc8e47..7ec5083 100644 --- a/content/browser/renderer_host/gpu_message_filter.cc +++ b/content/browser/renderer_host/gpu_message_filter.cc @@ -57,7 +57,7 @@ void GpuMessageFilter::OnEstablishGpuChannel( // to something like OnCreateGpuProcess. GpuProcessHost* host = GpuProcessHost::FromID(gpu_host_id_); if (!host) { - host = GpuProcessHost::GetForRenderer( + host = GpuProcessHost::GetForClient( render_process_id_, cause_for_gpu_launch); if (!host) { reply->set_reply_error(); |