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

Unified Diff: content/browser/renderer_host/pepper/pepper_gamepad_host.cc

Issue 2852803002: Remove base::SharedMemory::ShareToProcess. (Closed)
Patch Set: Compile error. Created 3 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/pepper/pepper_gamepad_host.cc
diff --git a/content/browser/renderer_host/pepper/pepper_gamepad_host.cc b/content/browser/renderer_host/pepper/pepper_gamepad_host.cc
index 775b7bcdbb402e538a33a57ac6835ea75807fb71..dd79a645761e979a2a1023b7e488b16dfb765354 100644
--- a/content/browser/renderer_host/pepper/pepper_gamepad_host.cc
+++ b/content/browser/renderer_host/pepper/pepper_gamepad_host.cc
@@ -20,7 +20,6 @@ PepperGamepadHost::PepperGamepadHost(BrowserPpapiHost* host,
PP_Instance instance,
PP_Resource resource)
: ResourceHost(host->GetPpapiHost(), instance, resource),
- browser_ppapi_host_(host),
gamepad_service_(device::GamepadService::GetInstance()),
is_started_(false),
weak_factory_(this) {}
@@ -30,7 +29,6 @@ PepperGamepadHost::PepperGamepadHost(device::GamepadService* gamepad_service,
PP_Instance instance,
PP_Resource resource)
: ResourceHost(host->GetPpapiHost(), instance, resource),
- browser_ppapi_host_(host),
gamepad_service_(gamepad_service),
is_started_(false),
weak_factory_(this) {}
@@ -71,8 +69,7 @@ int32_t PepperGamepadHost::OnRequestMemory(
void PepperGamepadHost::GotUserGesture(
const ppapi::host::ReplyMessageContext& context) {
base::SharedMemoryHandle handle =
- gamepad_service_->GetSharedMemoryHandleForProcess(
- browser_ppapi_host_->GetPluginProcess().Handle());
+ gamepad_service_->DuplicateSharedMemoryHandle();
context.params.AppendHandle(ppapi::proxy::SerializedHandle(
handle, sizeof(ppapi::ContentGamepadHardwareBuffer)));
« no previous file with comments | « content/browser/renderer_host/pepper/pepper_gamepad_host.h ('k') | content/browser/renderer_host/render_process_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698