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

Side by Side Diff: ppapi/proxy/ppb_flash_proxy.cc

Issue 5978003: Make IPC::Channel::Listener:OnMessageReceived have a return value indicating ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 12 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 | « ppapi/proxy/ppb_flash_proxy.h ('k') | ppapi/proxy/ppb_font_proxy.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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "ppapi/proxy/ppb_flash_proxy.h" 5 #include "ppapi/proxy/ppb_flash_proxy.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 #include "ppapi/c/dev/pp_file_info_dev.h" 9 #include "ppapi/c/dev/pp_file_info_dev.h"
10 #include "ppapi/c/dev/ppb_font_dev.h" 10 #include "ppapi/c/dev/ppb_font_dev.h"
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 } 217 }
218 218
219 const void* PPB_Flash_Proxy::GetSourceInterface() const { 219 const void* PPB_Flash_Proxy::GetSourceInterface() const {
220 return &ppb_flash; 220 return &ppb_flash;
221 } 221 }
222 222
223 InterfaceID PPB_Flash_Proxy::GetInterfaceId() const { 223 InterfaceID PPB_Flash_Proxy::GetInterfaceId() const {
224 return INTERFACE_ID_PPB_FLASH; 224 return INTERFACE_ID_PPB_FLASH;
225 } 225 }
226 226
227 void PPB_Flash_Proxy::OnMessageReceived(const IPC::Message& msg) { 227 bool PPB_Flash_Proxy::OnMessageReceived(const IPC::Message& msg) {
228 bool handled = true;
228 IPC_BEGIN_MESSAGE_MAP(PPB_Flash_Proxy, msg) 229 IPC_BEGIN_MESSAGE_MAP(PPB_Flash_Proxy, msg)
229 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_SetInstanceAlwaysOnTop, 230 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_SetInstanceAlwaysOnTop,
230 OnMsgSetInstanceAlwaysOnTop) 231 OnMsgSetInstanceAlwaysOnTop)
231 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_DrawGlyphs, 232 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_DrawGlyphs,
232 OnMsgDrawGlyphs) 233 OnMsgDrawGlyphs)
233 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_GetProxyForURL, 234 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_GetProxyForURL,
234 OnMsgGetProxyForURL) 235 OnMsgGetProxyForURL)
235 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_OpenModuleLocalFile, 236 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_OpenModuleLocalFile,
236 OnMsgOpenModuleLocalFile) 237 OnMsgOpenModuleLocalFile)
237 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_RenameModuleLocalFile, 238 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_RenameModuleLocalFile,
238 OnMsgRenameModuleLocalFile) 239 OnMsgRenameModuleLocalFile)
239 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_DeleteModuleLocalFileOrDir, 240 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_DeleteModuleLocalFileOrDir,
240 OnMsgDeleteModuleLocalFileOrDir) 241 OnMsgDeleteModuleLocalFileOrDir)
241 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_CreateModuleLocalDir, 242 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_CreateModuleLocalDir,
242 OnMsgCreateModuleLocalDir) 243 OnMsgCreateModuleLocalDir)
243 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_QueryModuleLocalFile, 244 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_QueryModuleLocalFile,
244 OnMsgQueryModuleLocalFile) 245 OnMsgQueryModuleLocalFile)
245 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_GetModuleLocalDirContents, 246 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_GetModuleLocalDirContents,
246 OnMsgGetModuleLocalDirContents) 247 OnMsgGetModuleLocalDirContents)
247 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_NavigateToURL, OnMsgNavigateToURL) 248 IPC_MESSAGE_HANDLER(PpapiHostMsg_PPBFlash_NavigateToURL, OnMsgNavigateToURL)
249 IPC_MESSAGE_UNHANDLED(handled = false)
248 IPC_END_MESSAGE_MAP() 250 IPC_END_MESSAGE_MAP()
249 // TODO(brettw) handle bad messages! 251 // TODO(brettw) handle bad messages!
252 return handled;
250 } 253 }
251 254
252 void PPB_Flash_Proxy::OnMsgSetInstanceAlwaysOnTop( 255 void PPB_Flash_Proxy::OnMsgSetInstanceAlwaysOnTop(
253 PP_Instance instance, 256 PP_Instance instance,
254 bool on_top) { 257 bool on_top) {
255 ppb_flash_target()->SetInstanceAlwaysOnTop(instance, on_top); 258 ppb_flash_target()->SetInstanceAlwaysOnTop(instance, on_top);
256 } 259 }
257 260
258 void PPB_Flash_Proxy::OnMsgDrawGlyphs( 261 void PPB_Flash_Proxy::OnMsgDrawGlyphs(
259 const pp::proxy::PPBFlash_DrawGlyphs_Params& params, 262 const pp::proxy::PPBFlash_DrawGlyphs_Params& params,
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 void PPB_Flash_Proxy::OnMsgNavigateToURL(PP_Instance instance, 353 void PPB_Flash_Proxy::OnMsgNavigateToURL(PP_Instance instance,
351 const std::string& url, 354 const std::string& url,
352 const std::string& target, 355 const std::string& target,
353 bool* result) { 356 bool* result) {
354 *result = ppb_flash_target()->NavigateToURL(instance, url.c_str(), 357 *result = ppb_flash_target()->NavigateToURL(instance, url.c_str(),
355 target.c_str()); 358 target.c_str());
356 } 359 }
357 360
358 } // namespace proxy 361 } // namespace proxy
359 } // namespace pp 362 } // namespace pp
OLDNEW
« no previous file with comments | « ppapi/proxy/ppb_flash_proxy.h ('k') | ppapi/proxy/ppb_font_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698