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

Side by Side Diff: content/ppapi_plugin/ppapi_thread.cc

Issue 10795051: Implement asynchronous interface/plumbing for GetDefaultPrintSettings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 5 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
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/ppapi_plugin/ppapi_thread.h" 5 #include "content/ppapi_plugin/ppapi_thread.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/process_util.h" 10 #include "base/process_util.h"
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBUDPSocket_BindACK, 113 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBUDPSocket_BindACK,
114 OnPluginDispatcherMessageReceived(msg)) 114 OnPluginDispatcherMessageReceived(msg))
115 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBTalk_GetPermissionACK, 115 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBTalk_GetPermissionACK,
116 OnPluginDispatcherMessageReceived(msg)) 116 OnPluginDispatcherMessageReceived(msg))
117 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBHostResolver_ResolveACK, 117 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBHostResolver_ResolveACK,
118 OnPluginDispatcherMessageReceived(msg)) 118 OnPluginDispatcherMessageReceived(msg))
119 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBNetworkMonitor_NetworkList, 119 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBNetworkMonitor_NetworkList,
120 OnPluginDispatcherMessageReceived(msg)) 120 OnPluginDispatcherMessageReceived(msg))
121 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBFlashDeviceID_GetReply, 121 IPC_MESSAGE_HANDLER_GENERIC(PpapiMsg_PPBFlashDeviceID_GetReply,
122 OnPluginDispatcherMessageReceived(msg)) 122 OnPluginDispatcherMessageReceived(msg))
123 IPC_MESSAGE_HANDLER_GENERIC(
124 PpapiMsg_PPBInstance_GetDefaultPrintSettingsComplete,
125 OnPluginDispatcherMessageReceived(msg))
123 IPC_MESSAGE_HANDLER(PpapiMsg_SetNetworkState, OnMsgSetNetworkState) 126 IPC_MESSAGE_HANDLER(PpapiMsg_SetNetworkState, OnMsgSetNetworkState)
124 IPC_END_MESSAGE_MAP() 127 IPC_END_MESSAGE_MAP()
125 return true; 128 return true;
126 } 129 }
127 void PpapiThread::OnChannelConnected(int32 peer_pid) { 130 void PpapiThread::OnChannelConnected(int32 peer_pid) {
128 #if defined(OS_WIN) 131 #if defined(OS_WIN)
129 if (is_broker_) 132 if (is_broker_)
130 peer_handle_.Set(::OpenProcess(PROCESS_DUP_HANDLE, FALSE, peer_pid)); 133 peer_handle_.Set(::OpenProcess(PROCESS_DUP_HANDLE, FALSE, peer_pid));
131 #endif 134 #endif
132 } 135 }
(...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after
374 ppapi::proxy::PluginGlobals::Get()->set_plugin_name( 377 ppapi::proxy::PluginGlobals::Get()->set_plugin_name(
375 path.BaseName().AsUTF8Unsafe()); 378 path.BaseName().AsUTF8Unsafe());
376 379
377 // plugin() is NULL when in-process. Which is fine, because this is 380 // plugin() is NULL when in-process. Which is fine, because this is
378 // just a hook for setting the process name. 381 // just a hook for setting the process name.
379 if (content::GetContentClient()->plugin()) { 382 if (content::GetContentClient()->plugin()) {
380 content::GetContentClient()->plugin()->PluginProcessStarted( 383 content::GetContentClient()->plugin()->PluginProcessStarted(
381 path.BaseName().RemoveExtension().LossyDisplayName()); 384 path.BaseName().RemoveExtension().LossyDisplayName());
382 } 385 }
383 } 386 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698