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

Side by Side Diff: content/renderer/pepper/renderer_ppapi_host_impl.cc

Issue 310293002: Make IPC::Channel polymorphic (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Another attempt to fix build breakage Created 6 years, 6 months 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « content/common/gpu/gpu_channel.h ('k') | ipc/ipc_channel.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/pepper/renderer_ppapi_host_impl.h" 5 #include "content/renderer/pepper/renderer_ppapi_host_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 blink::WebPluginContainer* RendererPpapiHostImpl::GetContainerForInstance( 169 blink::WebPluginContainer* RendererPpapiHostImpl::GetContainerForInstance(
170 PP_Instance instance) const { 170 PP_Instance instance) const {
171 PepperPluginInstanceImpl* instance_object = GetAndValidateInstance(instance); 171 PepperPluginInstanceImpl* instance_object = GetAndValidateInstance(instance);
172 if (!instance_object) 172 if (!instance_object)
173 return NULL; 173 return NULL;
174 return instance_object->container(); 174 return instance_object->container();
175 } 175 }
176 176
177 base::ProcessId RendererPpapiHostImpl::GetPluginPID() const { 177 base::ProcessId RendererPpapiHostImpl::GetPluginPID() const {
178 if (dispatcher_) 178 if (dispatcher_)
179 return dispatcher_->channel()->peer_pid(); 179 return dispatcher_->channel()->GetPeerPID();
180 return base::kNullProcessId; 180 return base::kNullProcessId;
181 } 181 }
182 182
183 bool RendererPpapiHostImpl::HasUserGesture(PP_Instance instance) const { 183 bool RendererPpapiHostImpl::HasUserGesture(PP_Instance instance) const {
184 PepperPluginInstanceImpl* instance_object = GetAndValidateInstance(instance); 184 PepperPluginInstanceImpl* instance_object = GetAndValidateInstance(instance);
185 if (!instance_object) 185 if (!instance_object)
186 return false; 186 return false;
187 187
188 if (instance_object->module()->permissions().HasPermission( 188 if (instance_object->module()->permissions().HasPermission(
189 ppapi::PERMISSION_BYPASS_USER_GESTURE)) 189 ppapi::PERMISSION_BYPASS_USER_GESTURE))
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
271 PepperPluginInstanceImpl* instance = 271 PepperPluginInstanceImpl* instance =
272 HostGlobals::Get()->GetInstance(pp_instance); 272 HostGlobals::Get()->GetInstance(pp_instance);
273 if (!instance) 273 if (!instance)
274 return NULL; 274 return NULL;
275 if (!instance->IsValidInstanceOf(module_)) 275 if (!instance->IsValidInstanceOf(module_))
276 return NULL; 276 return NULL;
277 return instance; 277 return instance;
278 } 278 }
279 279
280 } // namespace content 280 } // namespace content
OLDNEW
« no previous file with comments | « content/common/gpu/gpu_channel.h ('k') | ipc/ipc_channel.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698